[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] Make log_fn work on apples with no workarounds needed in ma...



Update of /home/or/cvsroot/src/common
In directory moria.mit.edu:/tmp/cvs-serv14905/src/common

Modified Files:
	log.h 
Log Message:
Make log_fn work on apples with no workarounds needed in main code

Index: log.h
===================================================================
RCS file: /home/or/cvsroot/src/common/log.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- log.h	14 Jun 2003 01:28:24 -0000	1.6
+++ log.h	17 Jun 2003 21:15:25 -0000	1.7
@@ -13,10 +13,13 @@
 void log(int severity, const char *format, ...);
 
 #ifdef __GNUC__
-#define log_fn(severity, format) \
-  log((severity), "%s(): " format , __PRETTY_FUNCTION__)
-#define log_fnf(severity, format, args...) \
-  log((severity), "%s(): " format , __PRETTY_FUNCTION__ ,  ##args)
+#ifdef __APPLE_CPP__
+#define log_fn(severity, args...) \
+  log((severity), __PRETTY_FUNCTION__ "(): " args)
+#else
+#define log_fn(severity, format, args...) \
+  log((severity), "%s(): " format, __PRETTY_FUNCTION__ , ##args)
+#endif
 #else
 #define log_fn log
 #define log_fnf log