Commit dcb7355b by Cedric Le Goater Committed by Daniel Lezcano

lxc: cleanup log

some headers and macros are now redundant Signed-off-by: 's avatarCedric Le Goater <legoater@free.fr> Acked-by: 's avatarDaniel Lezcano <dlezcano@fr.ibm.com> Signed-off-by: 's avatarDaniel Lezcano <dlezcano@fr.ibm.com>
parent 36eb9bde
......@@ -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);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment