gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r34874 - gnunet/src/core


From: gnunet
Subject: [GNUnet-SVN] r34874 - gnunet/src/core
Date: Sat, 10 Jan 2015 02:26:05 +0100

Author: bartpolot
Date: 2015-01-10 02:26:04 +0100 (Sat, 10 Jan 2015)
New Revision: 34874

Modified:
   gnunet/src/core/gnunet-service-core_sessions.c
Log:
Fixed inverting of same-priority bundled messages

This change causes the while loop to skip all messages of the same priority, 
effectively inserting the new message as the last of the same priority. As the 
messages are extraced from the head, inserting the message in the first 
available place caused order inversion.

Modified: gnunet/src/core/gnunet-service-core_sessions.c
===================================================================
--- gnunet/src/core/gnunet-service-core_sessions.c      2015-01-10 00:40:46 UTC 
(rev 34873)
+++ gnunet/src/core/gnunet-service-core_sessions.c      2015-01-10 01:26:04 UTC 
(rev 34874)
@@ -872,7 +872,7 @@
         GNUNET_TIME_relative_to_absolute (GNUNET_CONSTANTS_MAX_CORK_DELAY);
   pos = session->sme_head;
   while ( (NULL != pos) &&
-          (pos->priority > sme->priority) )
+          (pos->priority >= sme->priority) )
     pos = pos->next;
   if (NULL == pos)
     GNUNET_CONTAINER_DLL_insert_tail (session->sme_head,




reply via email to

[Prev in Thread] Current Thread [Next in Thread]