gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r33665 - gnunet/src/ats-tool


From: gnunet
Subject: [GNUnet-SVN] r33665 - gnunet/src/ats-tool
Date: Mon, 16 Jun 2014 10:03:26 +0200

Author: grothoff
Date: 2014-06-16 10:03:26 +0200 (Mon, 16 Jun 2014)
New Revision: 33665

Modified:
   gnunet/src/ats-tool/gnunet-ats.c
Log:
bugfix: only create another address entry if we did not have one already

Modified: gnunet/src/ats-tool/gnunet-ats.c
===================================================================
--- gnunet/src/ats-tool/gnunet-ats.c    2014-06-16 08:02:52 UTC (rev 33664)
+++ gnunet/src/ats-tool/gnunet-ats.c    2014-06-16 08:03:26 UTC (rev 33665)
@@ -397,14 +397,17 @@
         actx.res->bandwidth_out = bandwidth_out;
       }
     }
-    a = GNUNET_new (struct ATSAddress);
-    a->address = GNUNET_HELLO_address_copy(address);
-    a->bandwidth_in = bandwidth_in;
-    a->bandwidth_out = bandwidth_out;
-    GNUNET_CONTAINER_multipeermap_put (addresses,
-                                       &address->peer,
-                                       a,
-                                       
GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE);
+    else
+    {
+      a = GNUNET_new (struct ATSAddress);
+      a->address = GNUNET_HELLO_address_copy(address);
+      a->bandwidth_in = bandwidth_in;
+      a->bandwidth_out = bandwidth_out;
+      GNUNET_CONTAINER_multipeermap_put (addresses,
+                                         &address->peer,
+                                         a,
+                                         
GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE);
+    }
   }
 
   pr = GNUNET_malloc (sizeof (struct PendingResolutions) +




reply via email to

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