summaryrefslogtreecommitdiff
path: root/source3/nmbd/nmbd.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/nmbd/nmbd.c')
-rw-r--r--source3/nmbd/nmbd.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source3/nmbd/nmbd.c b/source3/nmbd/nmbd.c
index 880de7f91b..f8006a22a9 100644
--- a/source3/nmbd/nmbd.c
+++ b/source3/nmbd/nmbd.c
@@ -29,6 +29,8 @@ int global_nmb_port = -1;
extern BOOL global_in_nmbd;
+extern BOOL override_logfile;
+
/* are we running as a daemon ? */
static BOOL is_daemon;
@@ -623,8 +625,10 @@ static BOOL open_sockets(BOOL isdaemon, int port)
sys_srandom(time(NULL) ^ sys_getpid());
- slprintf(logfile, sizeof(logfile)-1, "%s/log.nmbd", dyn_LOGFILEBASE);
- lp_set_logfile(logfile);
+ if (!override_logfile) {
+ slprintf(logfile, sizeof(logfile)-1, "%s/log.nmbd", dyn_LOGFILEBASE);
+ lp_set_logfile(logfile);
+ }
fault_setup((void (*)(void *))fault_continue );