randyk 2003/09/25 00:40:32
Modified: src/modules/perl modperl_log.h Log: Reviewed by: stas In debug mode, for MP_FUNC, report __FILE__:__LINE__ in cases when __FUNCTION__ isn't available. Revision Changes Path 1.12 +4 -1 modperl-2.0/src/modules/perl/modperl_log.h Index: modperl_log.h =================================================================== RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_log.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- modperl_log.h 23 Sep 2003 08:04:42 -0000 1.11 +++ modperl_log.h 25 Sep 2003 07:40:32 -0000 1.12 @@ -1,6 +1,9 @@ #ifndef MODPERL_LOG_H #define MODPERL_LOG_H +#define MP_STRINGIFY(n) MP_STRINGIFY_HELPER(n) +#define MP_STRINGIFY_HELPER(n) #n + #ifdef MP_TRACE # if defined(__GNUC__) # if (__GNUC__ > 2) @@ -9,7 +12,7 @@ # define MP_FUNC __FUNCTION__ # endif # else -# define MP_FUNC NULL +# define MP_FUNC __FILE__ ":" MP_STRINGIFY(__LINE__) # endif #else # define MP_FUNC NULL