On 2016/09/26 15:20, Rafael Zalamena wrote:
> This diff fixes two compiler warnings when compiling with DEBUG define.
> 
> ok?

I think this would be preferred:

Index: timer.c
===================================================================
RCS file: /cvs/src/usr.sbin/snmpd/timer.c,v
retrieving revision 1.5
diff -u -p -r1.5 timer.c
--- timer.c     27 Aug 2016 01:50:07 -0000      1.5
+++ timer.c     26 Sep 2016 13:35:51 -0000
@@ -70,9 +70,9 @@ timer_cpu(int fd, short event, void *arg
                (void)percentages(CPUSTATES, cptime2, cp_time[n],
                    cp_old[n], cp_diff[n]);
 #ifdef DEBUG
-               log_debug("timer_cpu: cpu%d %d%% idle in %ds", n,
+               log_debug("timer_cpu: cpu%d %lld%% idle in %llds", n,
                    (cptime2[CP_IDLE] > 1000 ?
-                   1000 : (cptime2[CP_IDLE] / 10)), tv.tv_sec);
+                   1000 : (cptime2[CP_IDLE] / 10)), (long long) tv.tv_sec);
 #endif
        }
 
Also spotted:

usm.o: In function `usm_crypt':
usm.c:(.text+0x9ff): warning: warning: EVP_CipherFinal is often misused, please 
use EVP_CipherFinal_ex and EVP_CIPHER_CTX_cleanup

Reply via email to