svn commit: trunk/uClibc/libc/misc/syslog

psm at uclibc.org psm at uclibc.org
Tue Dec 6 14:44:44 UTC 2005


Author: psm
Date: 2005-12-06 06:43:37 -0800 (Tue, 06 Dec 2005)
New Revision: 12700

Log:
Add prototype for __time, #define time __time is not usable here

Modified:
   trunk/uClibc/libc/misc/syslog/syslog.c


Changeset:
Modified: trunk/uClibc/libc/misc/syslog/syslog.c
===================================================================
--- trunk/uClibc/libc/misc/syslog/syslog.c	2005-12-06 14:40:28 UTC (rev 12699)
+++ trunk/uClibc/libc/misc/syslog/syslog.c	2005-12-06 14:43:37 UTC (rev 12700)
@@ -31,7 +31,6 @@
  * SUCH DAMAGE.
  */
 
-#define time __time
 #define ctime __ctime
 #define sigaction __sigaction_internal
 
@@ -84,6 +83,7 @@
 #include <ctype.h>
 #include <signal.h>
 
+extern time_t __time (time_t *__timer) attribute_hidden;
 
 #ifdef __UCLIBC_HAS_THREADS__
 # include <pthread.h>
@@ -172,7 +172,7 @@
 	 * no longer than 64 characters plus length of the LogTag. So it's
 	 * safe to test only LogTag and use normal sprintf everywhere else.
 	 */
-	(void)time(&now);
+	(void)__time(&now);
 	stdp = p = tbuf + sprintf(tbuf, "<%d>%.15s ", pri, ctime(&now) + 4);
 	if (LogTag) {
 		if (__strlen(LogTag) < sizeof(tbuf) - 64)




More information about the uClibc-cvs mailing list