gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r10355 - gnunet/src/topology


From: gnunet
Subject: [GNUnet-SVN] r10355 - gnunet/src/topology
Date: Wed, 17 Feb 2010 22:48:52 +0100

Author: grothoff
Date: 2010-02-17 22:48:52 +0100 (Wed, 17 Feb 2010)
New Revision: 10355

Modified:
   gnunet/src/topology/gnunet-daemon-topology.c
Log:
fix NPE, fixing HELLO timeout increment on HELLO transmission failure

Modified: gnunet/src/topology/gnunet-daemon-topology.c
===================================================================
--- gnunet/src/topology/gnunet-daemon-topology.c        2010-02-17 20:23:58 UTC 
(rev 10354)
+++ gnunet/src/topology/gnunet-daemon-topology.c        2010-02-17 21:48:52 UTC 
(rev 10355)
@@ -910,6 +910,8 @@
     }
   consider_for_advertising (hello);
   pos = find_peer (peer);  
+  if (pos == NULL)
+    pos = make_peer (peer, hello, GNUNET_NO);
   GNUNET_assert (NULL != pos);
 #if DEBUG_TOPOLOGY
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
@@ -1213,7 +1215,6 @@
          memcpy (buf, pos->hello, want);
          GNUNET_CONTAINER_bloomfilter_add (pos->filter,
                                            &pl->id.hashPubKey);
-         pl->next_hello_allowed = GNUNET_TIME_relative_to_absolute 
(HELLO_ADVERTISEMENT_MIN_FREQUENCY);
 #if DEBUG_TOPOLOGY
          GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                      "Sending %u bytes of `%s's",
@@ -1222,6 +1223,7 @@
 #endif         
        }
     }
+  pl->next_hello_allowed = GNUNET_TIME_relative_to_absolute 
(HELLO_ADVERTISEMENT_MIN_FREQUENCY);
   pl->hello_delay_task 
     = GNUNET_SCHEDULER_add_now (sched,
                                &schedule_next_hello,





reply via email to

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