diff libfdcore/routing_dispatch.c @ 1238:8f9684264fe0

Change management of the p_reqin_count counter to be updated only on routable messages. This should limit the errors in the counter value resulting from rejected or discarded link-local messages.
author Sebastien Decugis <sdecugis@freediameter.net>
date Thu, 10 Oct 2013 16:08:46 +0200
parents e72c9dad62ac
children 681e8e55af27
line wrap: on
line diff
--- a/libfdcore/routing_dispatch.c	Sat Sep 14 12:56:05 2013 +0200
+++ b/libfdcore/routing_dispatch.c	Thu Oct 10 16:08:46 2013 +0200
@@ -414,7 +414,7 @@
 	if (is_loc) {
 		CHECK_FCT( fd_fifo_post(fd_g_incoming, pmsg) );
 	} else {
-		CHECK_FCT( fd_out_send(pmsg, NULL, peer) );
+		CHECK_FCT( fd_out_send(pmsg, NULL, peer, 1) );
 	}
 	
 	/* Done */
@@ -892,7 +892,7 @@
 		hdr->msg_hbhid = qry_hdr->msg_hbhid;
 
 		/* Push the message into this peer */
-		CHECK_FCT( fd_out_send(&msgptr, NULL, peer) );
+		CHECK_FCT( fd_out_send(&msgptr, NULL, peer, 1) );
 
 		/* We're done with this answer */
 		return 0;
@@ -1007,7 +1007,7 @@
 
 		if (fd_peer_getstate(peer) == STATE_OPEN) {
 			/* Send to this one */
-			CHECK_FCT_DO( fd_out_send(&msgptr, NULL, peer), continue );
+			CHECK_FCT_DO( fd_out_send(&msgptr, NULL, peer, 1), continue );
 			
 			/* If the sending was successful */
 			break;
"Welcome to our mercurial repository"