From 0f42b87326dfcbc0ffb856d6544f4824d4f4e636 Mon Sep 17 00:00:00 2001 From: Tharre Date: Thu, 24 Apr 2014 23:04:24 +0200 Subject: Convert __FILENAME__ to _FILENAME so it follows standard conventions --- src/dbg.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/dbg.h') diff --git a/src/dbg.h b/src/dbg.h index 41bebb9..5573f8e 100644 --- a/src/dbg.h +++ b/src/dbg.h @@ -6,9 +6,9 @@ #include #include -// #define __BFILE__ (strrchr(__FILE__, '/') ? strrchr(__FILE__, '/') + 1 : __FILE__) -#ifndef __FILENAME__ -#define __FILENAME__ __FILE__ + +#ifndef _FILENAME +#define _FILENAME __FILE__ #endif /* helper functions which help in replacing the GNU extension ##__VA_ARGS__ */ @@ -24,7 +24,7 @@ #define debug(...) log_err(__VA_ARGS__) #endif -#define log_err(...) LOG_HELPER(__FILENAME__, __LINE__, __VA_ARGS__) +#define log_err(...) LOG_HELPER(_FILENAME, __LINE__, __VA_ARGS__) #define fatal(...) \ {FATAL_HELPER(__VA_ARGS__, strerror(errno)); exit(EXIT_FAILURE);} #define fatal_(f,l,...) \ -- cgit v1.2.3-70-g09d2