[or-cvs] r17450: {tor} backport r17392: Compile without warnings on solaris (in tor/branches/tor-0_2_0-patches: . src/common)

arma at seul.org arma at seul.org
Tue Dec 2 22:50:18 UTC 2008


Author: arma
Date: 2008-12-02 17:50:18 -0500 (Tue, 02 Dec 2008)
New Revision: 17450

Modified:
   tor/branches/tor-0_2_0-patches/ChangeLog
   tor/branches/tor-0_2_0-patches/src/common/compat.c
Log:
backport r17392: Compile without warnings on solaris


Modified: tor/branches/tor-0_2_0-patches/ChangeLog
===================================================================
--- tor/branches/tor-0_2_0-patches/ChangeLog	2008-12-02 22:49:24 UTC (rev 17449)
+++ tor/branches/tor-0_2_0-patches/ChangeLog	2008-12-02 22:50:18 UTC (rev 17450)
@@ -4,6 +4,7 @@
       could make gcc generate non-functional binary search code. Bugfix
       on 0.2.0.10-alpha.
     - Build correctly on platforms without socklen_t.
+    - Compile without warnings on solaris.
     - Avoid potential crash on internal error during signature collection.
       Fixes bug 864.  Patch from rovv.
 

Modified: tor/branches/tor-0_2_0-patches/src/common/compat.c
===================================================================
--- tor/branches/tor-0_2_0-patches/src/common/compat.c	2008-12-02 22:49:24 UTC (rev 17449)
+++ tor/branches/tor-0_2_0-patches/src/common/compat.c	2008-12-02 22:50:18 UTC (rev 17450)
@@ -895,7 +895,8 @@
     return -1;
   } else {
     log_fn(CREDENTIAL_LOG_LEVEL, LD_GENERAL,
-           "UID is %u (real), %u (effective), %u (saved)", ruid, euid, suid);
+           "UID is %u (real), %u (effective), %u (saved)",
+           (unsigned)ruid, (unsigned)euid, (unsigned)suid);
   }
 #else
   /* getresuid is not present on MacOS X, so we can't get the saved (E)UID */
@@ -904,7 +905,8 @@
   (void)suid;
 
   log_fn(CREDENTIAL_LOG_LEVEL, LD_GENERAL,
-         "UID is %u (real), %u (effective), unknown (saved)", ruid, euid);
+         "UID is %u (real), %u (effective), unknown (saved)",
+         (unsigned)ruid, (unsigned)euid);
 #endif
 
   /* log GIDs */
@@ -914,7 +916,8 @@
     return -1;
   } else {
     log_fn(CREDENTIAL_LOG_LEVEL, LD_GENERAL,
-           "GID is %u (real), %u (effective), %u (saved)", rgid, egid, sgid);
+           "GID is %u (real), %u (effective), %u (saved)",
+           (unsigned)rgid, (unsigned)egid, (unsigned)sgid);
   }
 #else
   /* getresgid is not present on MacOS X, so we can't get the saved (E)GID */
@@ -922,7 +925,8 @@
   egid = getegid();
   (void)sgid;
   log_fn(CREDENTIAL_LOG_LEVEL, LD_GENERAL,
-         "GID is %u (real), %u (effective), unknown (saved)", rgid, egid);
+         "GID is %u (real), %u (effective), unknown (saved)",
+         (unsigned)rgid, (unsigned)egid);
 #endif
 
   /* log supplementary groups */



More information about the tor-commits mailing list