X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;ds=sidebyside;f=extras%2Fvolume_id%2Flib%2Flibvolume_id-private.h;h=3326bf371289d16b39f6720374b6689f1d2071e8;hb=3ab8ebf572cced0a63f8ba915d8494ef1784803d;hp=2ce46502c42b4d7824f584f594b3c4432aa27659;hpb=7744e869ecbfd2a508dbba46acfc2133a2f8f840;p=elogind.git diff --git a/extras/volume_id/lib/libvolume_id-private.h b/extras/volume_id/lib/libvolume_id-private.h index 2ce46502c..3326bf371 100644 --- a/extras/volume_id/lib/libvolume_id-private.h +++ b/extras/volume_id/lib/libvolume_id-private.h @@ -34,12 +34,15 @@ #define PACKED __attribute__((packed)) #endif +static inline void __attribute__ ((format(printf, 1, 2))) +log_null(const char *format, ...) {} + #define err(format, arg...) volume_id_log_fn(LOG_ERR, __FILE__, __LINE__, format, ##arg) #define info(format, arg...) volume_id_log_fn(LOG_INFO, __FILE__, __LINE__, format, ##arg) #ifdef DEBUG #define dbg(format, arg...) volume_id_log_fn(LOG_DEBUG, __FILE__, __LINE__, format, ##arg) #else -#define dbg(format, arg...) do { } while (0) +#define dbg(format, arg...) log_null(format, ##arg) #endif #if (__BYTE_ORDER == __LITTLE_ENDIAN)