From 8532e3182ab44d4ac84823e9798293f156192aaf Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Tue, 21 Aug 2007 14:22:16 +0000 Subject: r24599: patch from Karolin Seeger : smbd, nmbd and winbindd can be started with invalid options currently. The first patch attached would be a possible solution. It contains an exit if an invalid option has been used. The main problem is, that existing setups with wrong options or missing arguments in start scripts will break (which is the right behaviour from my point of view). metze --- source/smbd/server.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'source/smbd/server.c') diff --git a/source/smbd/server.c b/source/smbd/server.c index 491482eea62..3bb60058acb 100644 --- a/source/smbd/server.c +++ b/source/smbd/server.c @@ -855,7 +855,10 @@ extern void build_options(BOOL screen); case 'b': build_options(True); /* Display output to screen as well as debug */ exit(0); - break; + default: + d_fprintf(stderr, "\nInvalid option %s: %s\n", + poptBadOption(pc, 0), poptStrerror(opt)); + exit(1); } } -- cgit