retry faster
[oweals/gnunet.git] / src / topology / gnunet-daemon-topology.c
index efe22f1abd13a0e84ec2834edeb063eeb45706ad..08b1ba1c3c0effb852fa29cbd34b8880afc645ca 100644 (file)
@@ -59,7 +59,7 @@
  * For how long do we blacklist anyone under any cirumstances after a failed connection
  * attempt?
  */
-#define GREYLIST_AFTER_ATTEMPT_MAX GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 18)
+#define GREYLIST_AFTER_ATTEMPT_MAX GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 1)
 
 /**
  * How often do we at most advertise any HELLO to a peer?
@@ -271,11 +271,11 @@ whitelist_peers ()
  * Function called by core when our attempt to connect succeeded.
  *
  * @param cls the 'struct Peer' for which we issued the connect request
- * @param tc scheduler context
+ * @param success was the request transmitted
  */
 static void
 connect_completed_callback (void *cls,
-                           const struct GNUNET_SCHEDULER_TaskContext *tc)
+                           int success)
 {
   struct Peer *pos = cls;
 
@@ -772,7 +772,9 @@ disconnect_notify (void *cls,
                   GNUNET_PeerIdentity * peer)
 {
   struct Peer *pos;
+
+  if (0 == memcmp(&my_identity, peer, sizeof(struct GNUNET_PeerIdentity)))
+    return;
 #if DEBUG_TOPOLOGY
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Core told us that we disconnected from `%s'\n",