Module: sems
Branch: master
Commit: 204c92856797c102b3ffe42108d63aace3e63afd
URL:    
http://git.sip-router.org/cgi-bin/gitweb.cgi/sems/?a=commit;h=204c92856797c102b3ffe42108d63aace3e63afd

Author: Stefan Sayer <[email protected]>
Committer: Stefan Sayer <[email protected]>
Date:   Tue Mar 13 23:21:43 2012 +0100

b/f: log: using %lx and unsigned long for logging opaque pthread_t

---

 core/log.cpp |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/core/log.cpp b/core/log.cpp
index e45bfe3..f742ff9 100644
--- a/core/log.cpp
+++ b/core/log.cpp
@@ -124,11 +124,11 @@ void SyslogLogFac::log(int level, pid_t pid, pthread_t 
tid, const char* func, co
 
 # ifndef NO_THREADID_LOG
 #  ifdef LOG_LOC_DATA_ATEND
-  syslog(log2syslog_level[level], "%s: %s [#%p] [%s %s:%d]",
-      log_level2str[level], msg, tid, func, file, line);
+  syslog(log2syslog_level[level], "%s: %s [#%lx] [%s %s:%d]",
+        log_level2str[level], msg, (unsigned long)tid, func, file, line);
 #  else
-  syslog(log2syslog_level[level], "[#%p] [%s, %s:%d] %s: %s",
-        tid, func, file, line, log_level2str[level], msg);
+  syslog(log2syslog_level[level], "[#%lx] [%s, %s:%d] %s: %s",
+        (unsigned long)tid, func, file, line, log_level2str[level], msg);
 #  endif
 # else /* NO_THREADID_LOG */
 #  ifdef LOG_LOC_DATA_ATEND

_______________________________________________
Semsdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/semsdev

Reply via email to