diff options
Diffstat (limited to 'readconf.c')
-rw-r--r-- | readconf.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/readconf.c b/readconf.c index 7f2b5c172..50349e238 100644 --- a/readconf.c +++ b/readconf.c | |||
@@ -1741,8 +1741,7 @@ read_config_file_depth(const char *filename, struct passwd *pw, | |||
1741 | 1741 | ||
1742 | if (fstat(fileno(f), &sb) == -1) | 1742 | if (fstat(fileno(f), &sb) == -1) |
1743 | fatal("fstat %s: %s", filename, strerror(errno)); | 1743 | fatal("fstat %s: %s", filename, strerror(errno)); |
1744 | if (((sb.st_uid != 0 && sb.st_uid != getuid()) || | 1744 | if (!secure_permissions(&sb, getuid())) |
1745 | (sb.st_mode & 022) != 0)) | ||
1746 | fatal("Bad owner or permissions on %s", filename); | 1745 | fatal("Bad owner or permissions on %s", filename); |
1747 | } | 1746 | } |
1748 | 1747 | ||