mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-08-26 18:41:17 +00:00
src/logging.h: fix non-debug compile
This commit is contained in:
parent
12b6851d54
commit
261c3a8fd0
@ -1,3 +1,7 @@
|
||||
Fri Jan 9 18:29:11 GMT 2009 John Levon <levon@movementarian.org>
|
||||
|
||||
* src/logging.h: fix non-debug compile
|
||||
|
||||
Thu Jan 8 20:28:06 GMT 2009 John Levon <levon@movementarian.org>
|
||||
|
||||
Fixups after gnulib refresh
|
||||
|
@ -47,12 +47,6 @@
|
||||
do { } while (0)
|
||||
#define VIR_ERROR_INT(category, f, l, fmt,...) \
|
||||
do { } while (0)
|
||||
#define VIR_INFO_INT(category, fmt,...) \
|
||||
do { } while (0)
|
||||
#define VIR_WARN_INT(category, fmt,...) \
|
||||
do { } while (0)
|
||||
#define VIR_ERROR_INT(category, fmt,...) \
|
||||
do { } while (0)
|
||||
#endif /* !ENABLE_DEBUG */
|
||||
|
||||
#define VIR_DEBUG(fmt,...) \
|
||||
@ -114,15 +108,13 @@ typedef int (*virLogOutputFunc) (const char *category, int priority,
|
||||
*/
|
||||
typedef void (*virLogCloseFunc) (void *data);
|
||||
|
||||
#ifdef ENABLE_DEBUG
|
||||
|
||||
extern int virLogSetDefaultPriority(int priority);
|
||||
extern int virLogDefineFilter(const char *match, int priority, int flags);
|
||||
extern int virLogDefineOutput(virLogOutputFunc f, virLogCloseFunc c,
|
||||
void *data, int priority, int flags);
|
||||
|
||||
#if 0
|
||||
extern char *virLogGetDump(int flags);
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Internal logging API
|
||||
*/
|
||||
@ -136,4 +128,18 @@ extern void virLogMessage(const char *category, int priority,
|
||||
const char *funcname, long long linenr, int flags,
|
||||
const char *fmt, ...) ATTRIBUTE_FORMAT(printf, 6, 7);
|
||||
|
||||
#else /* ENABLE_DEBUG */
|
||||
|
||||
#define virLogSetDefaultPriority(p)
|
||||
#define virLogDefineFilter(m, p, f)
|
||||
#define virLogDefineOutput(func, c, d, p, f)
|
||||
#define virLogStartup()
|
||||
#define virLogReset()
|
||||
#define virLogShutdown()
|
||||
#define virLogParseFilters(f)
|
||||
#define virLogParseOutputs(o)
|
||||
#define virLogMessage(c, p, func, l, f, fmt, __VA_ARGS__)
|
||||
|
||||
#endif /* ENABLE_DEBUG */
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user