summaryrefslogtreecommitdiffstats
path: root/debug.h
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2008-01-22 16:45:10 +0000
committerRainer Gerhards <rgerhards@adiscon.com>2008-01-22 16:45:10 +0000
commit6ba75629051613c43b5d7cbc937a8243b250886c (patch)
treeda53b25727dd605c81ab3244d15afbd4b4c5cedb /debug.h
parent183242afef850508fc5a43e67c82d230ccb857e0 (diff)
downloadrsyslog-6ba75629051613c43b5d7cbc937a8243b250886c.tar.gz
rsyslog-6ba75629051613c43b5d7cbc937a8243b250886c.tar.xz
rsyslog-6ba75629051613c43b5d7cbc937a8243b250886c.zip
added debug support class
Diffstat (limited to 'debug.h')
-rw-r--r--debug.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/debug.h b/debug.h
new file mode 100644
index 00000000..ae079310
--- /dev/null
+++ b/debug.h
@@ -0,0 +1,36 @@
+/* debug.h
+ *
+ * Definitions for the debug and run-time analysis support module.
+ * Contains a lot of macros.
+ *
+ * Copyright 2008 Rainer Gerhards and Adiscon GmbH.
+ *
+ * This file is part of rsyslog.
+ *
+ * Rsyslog is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * Rsyslog is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Rsyslog. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * A copy of the GPL can be found in the file "COPYING" in this distribution.
+ */
+#ifndef DEBUG_H_INCLUDED
+#define DEBUG_H_INCLUDED
+
+/* external static data elements (some time to be replaced) */
+extern int Debug; /* debug flag - read-only after startup */
+extern int debugging_on; /* read-only, except on sig USR1 */
+
+/* prototypes */
+void sigsegvHdlr(int signum);
+void dbgprintf(char *fmt, ...) __attribute__((format(printf,1, 2)));
+
+#endif /* #ifndef DEBUG_H_INCLUDED */