gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r548 - in GNUnet/src/applications: advertising bootstrap_ht


From: grothoff
Subject: [GNUnet-SVN] r548 - in GNUnet/src/applications: advertising bootstrap_http
Date: Fri, 1 Apr 2005 15:50:53 -0800 (PST)

Author: grothoff
Date: 2005-04-01 15:50:51 -0800 (Fri, 01 Apr 2005)
New Revision: 548

Modified:
   GNUnet/src/applications/advertising/advertising.c
   GNUnet/src/applications/bootstrap_http/http.c
Log:
bugfix

Modified: GNUnet/src/applications/advertising/advertising.c
===================================================================
--- GNUnet/src/applications/advertising/advertising.c   2005-04-01 19:59:22 UTC 
(rev 547)
+++ GNUnet/src/applications/advertising/advertising.c   2005-04-01 23:50:51 UTC 
(rev 548)
@@ -290,6 +290,8 @@
   /* build message to send, ping must contain return-information,
      such as a selection of our HELOs... */
   mtu = transport->getMTU(tsession->ttype);
+  if (mtu == 0)
+    mtu = 2048; /* bound size */
   buffer = MALLOC(mtu);
   copy = MALLOC(HELO_Message_size(msg));
   memcpy(copy,
@@ -305,8 +307,10 @@
     LOG(LOG_INFO,
        _("Could not send HELOs+PING, ping buffer full.\n"));
   }
+  GNUNET_ASSERT(mtu > ntohs(ping->size));
   heloEnd = transport->getAdvertisedHELOs(mtu - ntohs(ping->size),
                                          buffer);
+  GNUNET_ASSERT(mtu - ntohs(ping->size) > heloEnd);
   if (heloEnd == -1) {
     LOG(LOG_WARNING,
        "'%s' failed. Will not send PING.\n",

Modified: GNUnet/src/applications/bootstrap_http/http.c
===================================================================
--- GNUnet/src/applications/bootstrap_http/http.c       2005-04-01 19:59:22 UTC 
(rev 547)
+++ GNUnet/src/applications/bootstrap_http/http.c       2005-04-01 23:50:51 UTC 
(rev 548)
@@ -237,8 +237,14 @@
 
   url = getConfigurationString("GNUNETD",
                               "HOSTLISTURL");
-  if (url == NULL)
+  if (url == NULL) {
+    LOG(LOG_DEBUG,
+        "No hostlist URL specified in configuration, will not bootstrap.\n");
     return;
+  }
+  LOG(LOG_DEBUG, 
+      "Trying to bootstrap with peers from '%s'\n",
+      url);
   cnt = 1;
   i = strlen(url);
   while (i > 0) {





reply via email to

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