]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Shuffle debug_log into Debug.h
authorAmos Jeffries <squid3@treenet.co.nz>
Thu, 16 Oct 2008 04:55:23 +0000 (17:55 +1300)
committerAmos Jeffries <squid3@treenet.co.nz>
Thu, 16 Oct 2008 04:55:23 +0000 (17:55 +1300)
src/Debug.h
src/debug.cc
src/fd.cc
test-suite/test_tools.cc

index 0409dac2f4638fe67ed7202b0acb6a7dda0f0434..61c7b69823435c6d5a90d8015e1518ee3d8aaa9d 100644 (file)
@@ -78,6 +78,8 @@ private:
     static int TheDepth; // level of nested debugging calls
 };
 
+extern FILE *debug_log;
+
 /* Debug stream */
 #define debugs(SECTION, LEVEL, CONTENT) \
    do { \
index 28bd0d37bc778c8726e99d4564767308f301f744..622036f0d9473968fd0c9b67a50b629bec67ce70 100644 (file)
@@ -40,7 +40,7 @@
 
 int Debug::Levels[MAX_DEBUG_SECTIONS];
 int Debug::level;
-
+FILE *debug_log = NULL;
 static char *debug_log_file = NULL;
 static int Ctx_Lock = 0;
 static const char *debugLogTime(void);
index cc98eb9fecbef9c2d45bf72e195e2583c67e0e4d..a14a1b978560fc5c6d5aff32bc9392347d6dda8e 100644 (file)
--- a/src/fd.cc
+++ b/src/fd.cc
@@ -36,6 +36,7 @@
 #include "squid.h"
 #include "fde.h"
 #include "SquidTime.h"
+#include "Debug.h"
 
 int default_read_method(int, char *, int);
 int default_write_method(int, const char *, int);
index 6e10b651a146ef6fb1ad9fa9c6212b45744a3032..953573b0a39de20bf6ce79bb1e656e1992051b5c 100644 (file)
 #include <iostream>
 #include <sstream>
 
+/* AYJ: the debug stuff here should really be in a stub_debug.cc file for tests to link */
+
+/* for correct pre-definitions of debug objects */
+#include "Debug.h"
+
+FILE *debug_log = NULL;
+
 void
 xassert(const char *msg, const char *file, int line)
 {