diff options
author | Andrew Tridgell <tridge@samba.org> | 1998-08-20 03:11:46 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 1998-08-20 03:11:46 +0000 |
commit | 852519282d43d7d12c103c01ca979952f041d683 (patch) | |
tree | 29e60ed5b110419bb6751cca9250100473e557ee | |
parent | 8487f959d10fe1ad1c8de0e97e623a2927165eaf (diff) | |
download | samba-852519282d43d7d12c103c01ca979952f041d683.tar.gz samba-852519282d43d7d12c103c01ca979952f041d683.tar.bz2 samba-852519282d43d7d12c103c01ca979952f041d683.zip |
testparm now prints a warning if the lock directory doesn't have 0644
permissions.
(This used to be commit 10303a78d4b12a03166db89202759cd745c516c5)
-rw-r--r-- | source3/utils/testparm.c | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/source3/utils/testparm.c b/source3/utils/testparm.c index 6f4ea23136..c7cbab91b8 100644 --- a/source3/utils/testparm.c +++ b/source3/utils/testparm.c @@ -47,13 +47,24 @@ extern pstring myhostname; void do_global_checks(void) { - if(lp_security() > SEC_SHARE && lp_revalidate(-1)) - printf("WARNING: the 'revalidate' parameter is ignored in all but \ + struct stat st; + if (lp_security() > SEC_SHARE && lp_revalidate(-1)) { + printf("WARNING: the 'revalidate' parameter is ignored in all but \ 'security=share' mode.\n"); + } - if( lp_wins_support() && *lp_wins_server() ) - printf("ERROR: both 'wins support = true' and 'wins server = <server>' \ + if (lp_wins_support() && *lp_wins_server()) { + printf("ERROR: both 'wins support = true' and 'wins server = <server>' \ cannot be set in the smb.conf file. nmbd will abort with this setting.\n"); + } + + if (!directory_exist(lp_lockdir(), &st)) { + printf("ERROR: lock directory %s does not exist\n", + lp_lockdir()); + } else if ((st.st_mode & 0666) != 0644) { + printf("WARNING: lock directory %s should have permissions 0644 for browsing to work\n", + lp_lockdir()); + } } int main(int argc, char *argv[]) |