summaryrefslogtreecommitdiff
path: root/source3/lib/debug.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib/debug.c')
-rw-r--r--source3/lib/debug.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/source3/lib/debug.c b/source3/lib/debug.c
index 2ba35c00db..27fa80ca3f 100644
--- a/source3/lib/debug.c
+++ b/source3/lib/debug.c
@@ -234,13 +234,13 @@ void debug_message(int msg_type, pid_t src, void *buf, size_t len)
/* Set the new DEBUGLEVEL_CLASS array from the pased array */
memcpy(DEBUGLEVEL_CLASS, buf, sizeof(DEBUGLEVEL_CLASS));
- DEBUG(3,("INFO: Debug class %s level = %d (pid %d from pid %d)\n",
+ DEBUG(1,("INFO: Debug class %s level = %d (pid %d from pid %d)\n",
classname_table[DBGC_ALL],
DEBUGLEVEL_CLASS[DBGC_ALL], getpid(), (int)src));
for (i=1; i<DBGC_LAST; i++) {
if (DEBUGLEVEL_CLASS[i])
- DEBUGADD(3,("INFO: Debug class %s level = %d\n",
+ DEBUGADD(1,("INFO: Debug class %s level = %d\n",
classname_table[i], DEBUGLEVEL_CLASS[i]));
}
}
@@ -263,6 +263,11 @@ void setup_logging(char *pname, BOOL interactive)
{
message_register(MSG_DEBUG, debug_message);
+ /* reset to allow multiple setup calls, going from interactive to
+ non-interactive */
+ stdout_logging = False;
+ dbf = NULL;
+
if (interactive) {
stdout_logging = True;
dbf = stdout;