summaryrefslogtreecommitdiffstats
path: root/libnetdata/log/log.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2021-02-07 11:45:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2021-02-07 11:45:55 +0000
commita8220ab2d293bb7f4b014b79d16b2fb05090fa93 (patch)
tree77f0a30f016c0925cf7ee9292e644bba183c2774 /libnetdata/log/log.h
parentAdding upstream version 1.19.0. (diff)
downloadnetdata-a8220ab2d293bb7f4b014b79d16b2fb05090fa93.tar.xz
netdata-a8220ab2d293bb7f4b014b79d16b2fb05090fa93.zip
Adding upstream version 1.29.0.upstream/1.29.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'libnetdata/log/log.h')
-rw-r--r--libnetdata/log/log.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/libnetdata/log/log.h b/libnetdata/log/log.h
index 1522ef9a..c99c1516 100644
--- a/libnetdata/log/log.h
+++ b/libnetdata/log/log.h
@@ -3,6 +3,10 @@
#ifndef NETDATA_LOG_H
#define NETDATA_LOG_H 1
+# ifdef __cplusplus
+extern "C" {
+# endif
+
#include "../libnetdata.h"
#define D_WEB_BUFFER 0x0000000000000001
@@ -37,6 +41,9 @@
#define D_POLLFD 0x0000000020000000
#define D_STREAM 0x0000000040000000
#define D_RRDENGINE 0x0000000100000000
+#define D_ACLK 0x0000000200000000
+#define D_METADATALOG 0x0000000400000000
+#define D_GUIDLOG 0x0000000800000000
#define D_SYSTEM 0x8000000000000000
//#define DEBUG (D_WEB_CLIENT_ACCESS|D_LISTENER|D_RRD_STATS)
@@ -86,6 +93,7 @@ static inline void debug_dummy(void) {}
#define infoerr(args...) error_int("INFO", __FILE__, __FUNCTION__, __LINE__, ##args)
#define error(args...) error_int("ERROR", __FILE__, __FUNCTION__, __LINE__, ##args)
#define fatal(args...) fatal_int(__FILE__, __FUNCTION__, __LINE__, ##args)
+#define fatal_assert(expr) ((expr) ? (void)(0) : fatal_int(__FILE__, __FUNCTION__, __LINE__, "Assertion `%s' failed", #expr))
extern void send_statistics(const char *action, const char *action_result, const char *action_data);
extern void debug_int( const char *file, const char *function, const unsigned long line, const char *fmt, ... ) PRINTFLIKE(4, 5);
@@ -94,4 +102,8 @@ extern void error_int( const char *prefix, const char *file, const char *functio
extern void fatal_int( const char *file, const char *function, const unsigned long line, const char *fmt, ... ) NORETURN PRINTFLIKE(4, 5);
extern void log_access( const char *fmt, ... ) PRINTFLIKE(1, 2);
+# ifdef __cplusplus
+}
+# endif
+
#endif /* NETDATA_LOG_H */