mirror of
https://git.proxmox.com/git/mirror_lxc
synced 2025-08-15 17:30:47 +00:00
lxc: cleanup log
some headers and macros are now redundant Signed-off-by: Cedric Le Goater <legoater@free.fr> Acked-by: Daniel Lezcano <dlezcano@fr.ibm.com> Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
This commit is contained in:
parent
36eb9bdef1
commit
dcb7355b2f
@ -27,7 +27,6 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/un.h>
|
||||
|
||||
#include "log.h"
|
||||
#include "af_unix.h"
|
||||
#include "error.h"
|
||||
|
||||
|
@ -127,7 +127,3 @@ extern int lxc_log_init(const char *file, int priority, const char *prefix)
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
#define MAXTIMELEN 47;
|
||||
#define ERRNO_FORMAT "%d (%s)"
|
||||
|
@ -244,21 +244,4 @@ extern struct lxc_log_category lxc_log_category_lxc;
|
||||
ERROR("%s - " format "\n", strerror(errno), ##__VA_ARGS__); \
|
||||
} while (0)
|
||||
|
||||
|
||||
#define lxc_log(format, level, ...) do { \
|
||||
fprintf(stderr, "[%s] \t%s:%d - " format "\n", \
|
||||
level, __FUNCTION__, __LINE__, ##__VA_ARGS__); \
|
||||
} while (0)
|
||||
|
||||
#define lxc_log_error(format, ...) lxc_log(format, "error", ##__VA_ARGS__);
|
||||
#define lxc_log_warning(format, ...) lxc_log(format, "warning", ##__VA_ARGS__);
|
||||
#define lxc_log_info(format, ...) lxc_log(format, "info", ##__VA_ARGS__);
|
||||
#define lxc_log_debug(format, ...) lxc_log(format, "debug", ##__VA_ARGS__);
|
||||
#define lxc_log_trace(format, ...) lxc_log(format, "trace", ##__VA_ARGS__);
|
||||
#define lxc_log_syserror(format, ...) do { \
|
||||
fprintf(stderr, "[syserr] \t%s:%d: %s - " format "\n", \
|
||||
__FUNCTION__, __LINE__, strerror(errno), \
|
||||
##__VA_ARGS__); \
|
||||
} while (0)
|
||||
|
||||
#endif
|
||||
|
@ -27,7 +27,6 @@
|
||||
#include <dirent.h>
|
||||
|
||||
#include "parse.h"
|
||||
#include "log.h"
|
||||
#include <lxc/log.h>
|
||||
|
||||
lxc_log_define(lxc_parse, lxc);
|
||||
|
Loading…
Reference in New Issue
Block a user