gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r14635 - gnunet/src/vpn


From: gnunet
Subject: [GNUnet-SVN] r14635 - gnunet/src/vpn
Date: Mon, 14 Mar 2011 16:16:28 +0100

Author: toelke
Date: 2011-03-14 16:16:28 +0100 (Mon, 14 Mar 2011)
New Revision: 14635

Modified:
   gnunet/src/vpn/gnunet-daemon-exit.c
   gnunet/src/vpn/gnunet-service-dns.c
Log:
fixed FIXMEs

Modified: gnunet/src/vpn/gnunet-daemon-exit.c
===================================================================
--- gnunet/src/vpn/gnunet-daemon-exit.c 2011-03-14 15:03:52 UTC (rev 14634)
+++ gnunet/src/vpn/gnunet-daemon-exit.c 2011-03-14 15:16:28 UTC (rev 14635)
@@ -292,21 +292,23 @@
        {     
          if (NULL == (hostname = strstr (redirect, ":")))
            {
-             // FIXME: bitch
+              GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Warning: option %s is not 
formatted correctly!\n", redirect);
              continue;
            }
          hostname[0] = '\0';
          hostname++;
          if (NULL == (hostport = strstr (hostname, ":")))
            {
-             // FIXME: bitch
+              GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Warning: option %s is not 
formatted correctly!\n", redirect);
              continue;
            }
          hostport[0] = '\0';
          hostport++;
          
           int local_port = atoi (redirect);
-          GNUNET_assert ((local_port > 0) && (local_port < 65536)); // FIXME: 
don't crash!!!
+          if (!((local_port > 0) && (local_port < 65536)))
+            GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Warning: %s is not a 
correct port.", redirect);
+
           *desc = local_port;
 
           GNUNET_CRYPTO_hash (desc, sizeof (GNUNET_HashCode) + 2, &hash);
@@ -642,7 +644,7 @@
   };
   mesh_handle = GNUNET_MESH_connect(cfg_,
                                    NULL,
-                                   NULL, /* FIXME */
+                                   NULL,
                                    handlers);
 
   cfg = cfg_;

Modified: gnunet/src/vpn/gnunet-service-dns.c
===================================================================
--- gnunet/src/vpn/gnunet-service-dns.c 2011-03-14 15:03:52 UTC (rev 14634)
+++ gnunet/src/vpn/gnunet-service-dns.c 2011-03-14 15:16:28 UTC (rev 14635)
@@ -595,12 +595,13 @@
         {
           if (NULL == (hostname = strstr (redirect, ":")))
             {
-              // FIXME: bitch
+              GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Warning: option %s is not 
formatted correctly!\n", redirect);
               continue;
             }
           hostname[0] = '\0';
           local_port = atoi (redirect);
-          GNUNET_assert ((local_port > 0) && (local_port < 65536)); // FIXME: 
don't crash!!!
+          if (!((local_port > 0) && (local_port < 65536)))
+            GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Warning: %s is not a 
correct port.", redirect);
 
           ret |= (0xFFFF & htons(local_port));
           ret <<= 16;
@@ -623,12 +624,13 @@
         {
           if (NULL == (hostname = strstr (redirect, ":")))
             {
-              // FIXME: bitch
+              GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Warning: option %s is not 
formatted correctly!\n", redirect);
               continue;
             }
           hostname[0] = '\0';
           local_port = atoi (redirect);
-          GNUNET_assert ((local_port > 0) && (local_port < 65536)); // FIXME: 
don't crash!!!
+          if (!((local_port > 0) && (local_port < 65536)))
+            GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Warning: %s is not a 
correct port.", redirect);
 
           ret |= (0xFFFF & htons(local_port));
           ret <<= 16;




reply via email to

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