From a38fad422943c4266348af584172090435b4e949 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Sun, 3 Feb 2008 13:22:34 +0100 Subject: [PATCH] Make utility programs abort on internal error Until now, they tried to recover and continue (debug off). That's appropriate only for the server. The server could be told to abort instead (debug on, selected by option -d), but not the utility programs. Change debug to be on by default, and switch it off early in the server's main(). No functional change for the server. --- src/lib/gen/log.c | 2 +- src/server/main.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/gen/log.c b/src/lib/gen/log.c index 1a49c0d3..4196bcd0 100644 --- a/src/lib/gen/log.c +++ b/src/lib/gen/log.c @@ -46,7 +46,7 @@ #include "prototypes.h" /* Debugging? If yes call abort() on internal error. */ -int debug = 0; +int debug = 1; static char logfile[32]; static int logfd = -1; diff --git a/src/server/main.c b/src/server/main.c index b7d79eea..20d1a264 100644 --- a/src/server/main.c +++ b/src/server/main.c @@ -133,6 +133,8 @@ main(int argc, char **argv) int op, sig; unsigned seed = time(NULL); + debug = 0; + #ifdef _WIN32 # define XOPTS "iI:uU:" #else