2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-08-22 09:57:41 +00:00

Fix compiler warning on systems where mode_t is not unsigned int,

such as 32-bit Solaris.
This commit is contained in:
Todd C. Miller 2015-03-02 13:58:45 -07:00
parent c9d4e1084c
commit ea514dc391

View File

@ -620,7 +620,7 @@ install_sudoers(struct sudoersfile *sp, bool oldperms)
} }
if (chmod(sp->tpath, sudoers_mode) != 0) { if (chmod(sp->tpath, sudoers_mode) != 0) {
sudo_warn(U_("unable to change mode of %s to 0%o"), sp->tpath, sudo_warn(U_("unable to change mode of %s to 0%o"), sp->tpath,
sudoers_mode); (unsigned int)sudoers_mode);
goto done; goto done;
} }
} }
@ -818,7 +818,7 @@ check_owner(const char *path, bool quiet)
ok = false; ok = false;
if (!quiet) { if (!quiet) {
fprintf(stderr, _("%s: bad permissions, should be mode 0%o\n"), fprintf(stderr, _("%s: bad permissions, should be mode 0%o\n"),
path, sudoers_mode); path, (unsigned int)sudoers_mode);
} }
} }
} }