From: Kay Sievers Date: Wed, 4 Apr 2012 11:14:29 +0000 (+0200) Subject: udev: enable logging X-Git-Tag: v183~446 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0c9507fe2469c2da2ffbc9c8a698cc888cef40fc;p=systemd udev: enable logging --- diff --git a/src/udev/libudev-private.h b/src/udev/libudev-private.h index 4bbd8422..001c5785 100644 --- a/src/udev/libudev-private.h +++ b/src/udev/libudev-private.h @@ -31,19 +31,13 @@ udev_log_null(struct udev *udev, const char *format, ...) {} udev_log(udev, prio, __FILE__, __LINE__, __FUNCTION__, ## arg); \ } while (0) -#ifdef ENABLE_LOGGING -# ifdef ENABLE_DEBUG -# define dbg(udev, arg...) udev_log_cond(udev, LOG_DEBUG, ## arg) -# else -# define dbg(udev, arg...) udev_log_null(udev, ## arg) -# endif -# define info(udev, arg...) udev_log_cond(udev, LOG_INFO, ## arg) -# define err(udev, arg...) udev_log_cond(udev, LOG_ERR, ## arg) +#ifdef ENABLE_DEBUG +# define dbg(udev, arg...) udev_log_cond(udev, LOG_DEBUG, ## arg) #else # define dbg(udev, arg...) udev_log_null(udev, ## arg) -# define info(udev, arg...) udev_log_null(udev, ## arg) -# define err(udev, arg...) udev_log_null(udev, ## arg) #endif +#define info(udev, arg...) udev_log_cond(udev, LOG_INFO, ## arg) +#define err(udev, arg...) udev_log_cond(udev, LOG_ERR, ## arg) #define UDEV_EXPORT __attribute__ ((visibility("default")))