comparison libfdcore/p_sr.c @ 1078:74bba7975864

Cleanup the timing data and fd_msg_log feature that will be replaced by the new hooks mechanism. Kept the calls to fd_msg_log in comments to find the locations easily. WORK IN PROGRESS.
author Sebastien Decugis <sdecugis@freediameter.net>
date Tue, 30 Apr 2013 15:37:57 +0800
parents b3d623f04b6d
children 6ce5c99a40af
comparison
equal deleted inserted replaced
1069:544fa1be79a9 1078:74bba7975864
116 /* Call it */ 116 /* Call it */
117 (*expirecb)(data, ed->sentto->p_hdr.info.pi_diamid, ed->sentto->p_hdr.info.pi_diamidlen, &ed->request); 117 (*expirecb)(data, ed->sentto->p_hdr.info.pi_diamid, ed->sentto->p_hdr.info.pi_diamidlen, &ed->request);
118 118
119 /* If the callback did not dispose of the message, do it now */ 119 /* If the callback did not dispose of the message, do it now */
120 if (ed->request) { 120 if (ed->request) {
121 fd_msg_log(FD_MSG_LOG_DROPPED, ed->request, "Expiration period completed without an answer, and the expiry callback did not dispose of the message."); 121 //fd_msg_log(FD_MSG_LOG_DROPPED, ed->request, "Expiration period completed without an answer, and the expiry callback did not dispose of the message.");
122 CHECK_FCT_DO( fd_msg_free(ed->request), /* ignore */ ); 122 CHECK_FCT_DO( fd_msg_free(ed->request), /* ignore */ );
123 } 123 }
124 124
125 free(ed); 125 free(ed);
126 126
322 hdr->msg_flags |= CMD_FLAG_RETRANSMIT; 322 hdr->msg_flags |= CMD_FLAG_RETRANSMIT;
323 323
324 /* Requeue for sending to another peer */ 324 /* Requeue for sending to another peer */
325 CHECK_FCT_DO( ret = fd_fifo_post(fd_g_outgoing, &sr->req), 325 CHECK_FCT_DO( ret = fd_fifo_post(fd_g_outgoing, &sr->req),
326 { 326 {
327 fd_msg_log( FD_MSG_LOG_DROPPED, sr->req, "Internal error: error while requeuing during failover: %s", strerror(ret) ); 327 //fd_msg_log( FD_MSG_LOG_DROPPED, sr->req, "Internal error: error while requeuing during failover: %s", strerror(ret) );
328 CHECK_FCT_DO(fd_msg_free(sr->req), /* What can we do more? */) 328 CHECK_FCT_DO(fd_msg_free(sr->req), /* What can we do more? */)
329 }); 329 });
330 } else { 330 } else {
331 /* Just free the request. */ 331 /* Just free the request. */
332 fd_msg_log( FD_MSG_LOG_DROPPED, sr->req, "Sent & unanswered local message discarded during failover." ); 332 //fd_msg_log( FD_MSG_LOG_DROPPED, sr->req, "Sent & unanswered local message discarded during failover." );
333 CHECK_FCT_DO(fd_msg_free(sr->req), /* Ignore */); 333 CHECK_FCT_DO(fd_msg_free(sr->req), /* Ignore */);
334 } 334 }
335 free(sr); 335 free(sr);
336 } 336 }
337 /* The list of expiring requests must be empty now */ 337 /* The list of expiring requests must be empty now */
"Welcome to our mercurial repository"