Home | History | Annotate | Download | only in fsck
      1 /**
      2  *
      3  * Various things common for all utilities
      4  *
      5  */
      6 
      7 #ifndef __QUOTA_COMMON_H__
      8 #define __QUOTA_COMMON_H__
      9 
     10 #undef DEBUG_QUOTA
     11 
     12 #ifndef __attribute__
     13 # if !defined __GNUC__ || __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 8) || __STRICT_ANSI__
     14 #  define __attribute__(x)
     15 # endif
     16 #endif
     17 
     18 #define log_err(format, arg ...)					\
     19 	fprintf(stderr, "[ERROR] %s:%d:%s:: " format "\n",		\
     20 		__FILE__, __LINE__, __func__, ## arg)
     21 
     22 #ifdef DEBUG_QUOTA
     23 # define log_debug(format, arg ...)					\
     24 	fprintf(stderr, "[DEBUG] %s:%d:%s:: " format "\n",		\
     25 		__FILE__, __LINE__, __func__, ## arg)
     26 #else
     27 # define log_debug(...)
     28 #endif
     29 
     30 #endif /* __QUOTA_COMMON_H__ */
     31