comparison libfdcore/p_out.c @ 1027:0117a7746b21

Fix a number of errors and warnings introduced/highlighted by recent commits
author Sebastien Decugis <sdecugis@freediameter.net>
date Mon, 15 Apr 2013 15:17:07 +0800
parents 357c2f892d24
children 74bba7975864
comparison
equal deleted inserted replaced
1026:beb375690453 1027:0117a7746b21
82 struct timespec rcvon, delay; 82 struct timespec rcvon, delay;
83 83
84 (void) fd_msg_ts_get_recv(cpy_for_logs_only, &rcvon); 84 (void) fd_msg_ts_get_recv(cpy_for_logs_only, &rcvon);
85 if (rcvon.tv_sec != 0 || rcvon.tv_nsec != 0) { 85 if (rcvon.tv_sec != 0 || rcvon.tv_nsec != 0) {
86 TS_DIFFERENCE( &delay, &rcvon, &senton); 86 TS_DIFFERENCE( &delay, &rcvon, &senton);
87 fd_msg_log( FD_MSG_LOG_TIMING, cpy_for_logs_only, "Forwarded in %d.%06.6d sec", delay.tv_sec, delay.tv_nsec/1000); 87 fd_msg_log( FD_MSG_LOG_TIMING, cpy_for_logs_only, "Forwarded in %ld.%6.6ld sec", (long)delay.tv_sec, delay.tv_nsec/1000);
88 } else { /* We log the answer time only for answers generated locally */ 88 } else { /* We log the answer time only for answers generated locally */
89 if (!msg_is_a_req) { 89 if (!msg_is_a_req) {
90 /* get the matching request */ 90 /* get the matching request */
91 struct msg * req; 91 struct msg * req;
92 struct timespec reqrcvon; 92 struct timespec reqrcvon;
93 (void) fd_msg_answ_getq(cpy_for_logs_only, &req); 93 (void) fd_msg_answ_getq(cpy_for_logs_only, &req);
94 (void) fd_msg_ts_get_recv(req, &reqrcvon); 94 (void) fd_msg_ts_get_recv(req, &reqrcvon);
95 TS_DIFFERENCE( &delay, &reqrcvon, &senton); 95 TS_DIFFERENCE( &delay, &reqrcvon, &senton);
96 fd_msg_log( FD_MSG_LOG_TIMING, cpy_for_logs_only, "Answered in %d.%06.6d sec", delay.tv_sec, delay.tv_nsec/1000); 96 fd_msg_log( FD_MSG_LOG_TIMING, cpy_for_logs_only, "Answered in %ld.%6.6ld sec", (long)delay.tv_sec, delay.tv_nsec/1000);
97 } 97 }
98 } 98 }
99 } 99 }
100 100
101 /* Send the message */ 101 /* Send the message */
"Welcome to our mercurial repository"