gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r21568 - in gnunet/src: core dns dv exit fs statistics tran


From: gnunet
Subject: [GNUnet-SVN] r21568 - in gnunet/src: core dns dv exit fs statistics transport vpn
Date: Thu, 24 May 2012 11:35:37 +0200

Author: wachs
Date: 2012-05-24 11:35:37 +0200 (Thu, 24 May 2012)
New Revision: 21568

Modified:
   gnunet/src/core/gnunet-service-core_clients.c
   gnunet/src/core/gnunet-service-core_kx.c
   gnunet/src/dns/gnunet-service-dns.c
   gnunet/src/dv/gnunet-service-dv.c
   gnunet/src/exit/gnunet-daemon-exit.c
   gnunet/src/fs/fs_dirmetascan.c
   gnunet/src/statistics/gnunet-service-statistics.c
   gnunet/src/transport/gnunet-helper-transport-wlan-dummy.c
   gnunet/src/transport/gnunet-service-transport.c
   gnunet/src/transport/plugin_transport_http_client.c
   gnunet/src/transport/plugin_transport_http_server.c
   gnunet/src/transport/plugin_transport_udp.c
   gnunet/src/transport/plugin_transport_udp_broadcasting.c
   gnunet/src/transport/plugin_transport_wlan.c
   gnunet/src/vpn/gnunet-service-vpn.c
Log:
- adding return value to mst callback


Modified: gnunet/src/core/gnunet-service-core_clients.c
===================================================================
--- gnunet/src/core/gnunet-service-core_clients.c       2012-05-24 08:43:24 UTC 
(rev 21567)
+++ gnunet/src/core/gnunet-service-core_clients.c       2012-05-24 09:35:37 UTC 
(rev 21568)
@@ -506,7 +506,7 @@
  * @param client reservation request ('struct GSC_ClientActiveRequest')
  * @param message the actual message
  */
-static void
+static int
 client_tokenizer_callback (void *cls, void *client,
                            const struct GNUNET_MessageHeader *message)
 {
@@ -546,6 +546,7 @@
                                 GNUNET_CORE_OPTION_SEND_HDR_OUTBOUND);  
     GSC_SESSIONS_transmit (car, message, tc->cork);
   }
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/core/gnunet-service-core_kx.c
===================================================================
--- gnunet/src/core/gnunet-service-core_kx.c    2012-05-24 08:43:24 UTC (rev 
21567)
+++ gnunet/src/core/gnunet-service-core_kx.c    2012-05-24 09:35:37 UTC (rev 
21568)
@@ -1658,7 +1658,7 @@
  * @param client who sent us the message (struct GSC_KeyExchangeInfo)
  * @param m the message
  */
-static void
+static int
 deliver_message (void *cls, void *client, const struct GNUNET_MessageHeader *m)
 {
   struct DeliverMessageContext *dmc = client;
@@ -1668,7 +1668,7 @@
   case GNUNET_MESSAGE_TYPE_CORE_BINARY_TYPE_MAP:
   case GNUNET_MESSAGE_TYPE_CORE_COMPRESSED_TYPE_MAP:
     GSC_SESSIONS_set_typemap (dmc->peer, m);
-    return;
+    return GNUNET_OK;
   default:
     GSC_CLIENTS_deliver_message (dmc->peer, dmc->atsi, dmc->atsi_count, m,
                                  ntohs (m->size),
@@ -1677,6 +1677,7 @@
                                  sizeof (struct GNUNET_MessageHeader),
                                  GNUNET_CORE_OPTION_SEND_HDR_INBOUND);
   }
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/dns/gnunet-service-dns.c
===================================================================
--- gnunet/src/dns/gnunet-service-dns.c 2012-05-24 08:43:24 UTC (rev 21567)
+++ gnunet/src/dns/gnunet-service-dns.c 2012-05-24 09:35:37 UTC (rev 21568)
@@ -1239,7 +1239,7 @@
  * @param client identification of the client
  * @param message the actual message, a DNS request we should handle
  */
-static void
+static int
 process_helper_messages (void *cls GNUNET_UNUSED, void *client,
                         const struct GNUNET_MessageHeader *message)
 {
@@ -1260,7 +1260,7 @@
   {
     /* non-IP packet received on TUN!? */
     GNUNET_break (0);
-    return;
+    return GNUNET_OK;
   }
   msize -= sizeof (struct GNUNET_MessageHeader);
   tun = (const struct GNUNET_TUN_Layer2PacketHeader *) &message[1];
@@ -1279,7 +1279,7 @@
       /* non-IP/UDP packet received on TUN (or with options) */
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
                  _("Received malformed IPv4-UDP packet on TUN interface.\n"));
-      return;
+      return GNUNET_OK;
     }
     udp = (const struct GNUNET_TUN_UdpHeader*) &ip4[1];
     msize -= sizeof (struct GNUNET_TUN_IPv4Header);
@@ -1295,7 +1295,7 @@
       /* non-IP/UDP packet received on TUN (or with extensions) */
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
                  _("Received malformed IPv6-UDP packet on TUN interface.\n"));
-      return;
+      return GNUNET_OK;
     }
     udp = (const struct GNUNET_TUN_UdpHeader*) &ip6[1];
     msize -= sizeof (struct GNUNET_TUN_IPv6Header);
@@ -1306,7 +1306,7 @@
                _("Got non-IP packet with %u bytes and protocol %u from TUN\n"),
                (unsigned int) msize,
                ntohs (tun->proto));
-    return;
+    return GNUNET_OK;
   }
   if (msize <= sizeof (struct GNUNET_TUN_UdpHeader) + sizeof (struct 
GNUNET_TUN_DnsHeader))
   {    
@@ -1314,7 +1314,7 @@
     GNUNET_STATISTICS_update (stats,
                              gettext_noop ("# Non-DNS UDP packet received via 
TUN interface"),
                              1, GNUNET_NO);
-    return;
+    return GNUNET_OK;
   }
   msize -= sizeof (struct GNUNET_TUN_UdpHeader);
   dns = (const struct GNUNET_TUN_DnsHeader*) &udp[1];
@@ -1381,6 +1381,7 @@
                            1, GNUNET_NO);
   /* start request processing state machine */
   next_phase (rr);
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/dv/gnunet-service-dv.c
===================================================================
--- gnunet/src/dv/gnunet-service-dv.c   2012-05-24 08:43:24 UTC (rev 21567)
+++ gnunet/src/dv/gnunet-service-dv.c   2012-05-24 09:35:37 UTC (rev 21568)
@@ -1288,7 +1288,7 @@
  * @param client the TokenizedMessageContext which contains message information
  * @param message the actual message
  */
-void
+int
 tokenized_message_handler (void *cls, void *client,
                            const struct GNUNET_MessageHeader *message)
 {
@@ -1312,6 +1312,7 @@
     send_to_plugin (ctx->peer, message, ntohs (message->size),
                     &ctx->distant->identity, ctx->distant->cost);
   }
+  return GNUNET_OK;
 }
 
 #if DELAY_FORWARDS

Modified: gnunet/src/exit/gnunet-daemon-exit.c
===================================================================
--- gnunet/src/exit/gnunet-daemon-exit.c        2012-05-24 08:43:24 UTC (rev 
21567)
+++ gnunet/src/exit/gnunet-daemon-exit.c        2012-05-24 09:35:37 UTC (rev 
21568)
@@ -953,7 +953,7 @@
  * @param client unsued
  * @param message message received from helper
  */
-static void
+static int
 message_token (void *cls GNUNET_UNUSED, void *client GNUNET_UNUSED,
                const struct GNUNET_MessageHeader *message)
 {
@@ -970,13 +970,13 @@
   if (ntohs (message->type) != GNUNET_MESSAGE_TYPE_VPN_HELPER)
   {
     GNUNET_break (0);
-    return;
+    return GNUNET_OK;
   }
   size = ntohs (message->size);
   if (size < sizeof (struct GNUNET_TUN_Layer2PacketHeader) + sizeof (struct 
GNUNET_MessageHeader))
   {
     GNUNET_break (0);
-    return;
+    return GNUNET_OK;
   }
   GNUNET_STATISTICS_update (stats,
                            gettext_noop ("# Bytes received from TUN"),
@@ -993,20 +993,20 @@
       {
        /* Kernel to blame? */
        GNUNET_break (0);
-       return;
+        return GNUNET_OK;
       }
       pkt4 = (const struct GNUNET_TUN_IPv4Header *) &pkt_tun[1];
       if (size != ntohs (pkt4->total_length))
       {
        /* Kernel to blame? */
        GNUNET_break (0);
-       return;
+        return GNUNET_OK;
       }
       if (pkt4->header_length * 4 != sizeof (struct GNUNET_TUN_IPv4Header))
       {
        GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
                    _("IPv4 packet options received.  Ignored.\n"));
-       return;
+        return GNUNET_OK;
       }
       
       size -= sizeof (struct GNUNET_TUN_IPv4Header);
@@ -1034,7 +1034,7 @@
        GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
                    _("IPv4 packet with unsupported next header %u received.  
Ignored.\n"),
                    (int) pkt4->protocol);
-       return;
+        return GNUNET_OK;
       }
     }
     break;
@@ -1046,14 +1046,14 @@
       {
        /* Kernel to blame? */
        GNUNET_break (0);
-       return;
+        return GNUNET_OK;
       }
       pkt6 = (struct GNUNET_TUN_IPv6Header *) &pkt_tun[1];
       if (size != ntohs (pkt6->payload_length) + sizeof (struct 
GNUNET_TUN_IPv6Header))
       {
        /* Kernel to blame? */
        GNUNET_break (0);
-       return;
+        return GNUNET_OK;
       }
       size -= sizeof (struct GNUNET_TUN_IPv6Header);
       switch (pkt6->next_header)
@@ -1080,7 +1080,7 @@
        GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
                    _("IPv6 packet with unsupported next header %d received.  
Ignored.\n"),
                     pkt6->next_header);
-       return;
+        return GNUNET_OK;
       }
     }
     break;
@@ -1090,6 +1090,7 @@
                ntohs (pkt_tun->proto));
     break;
   }
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/fs/fs_dirmetascan.c
===================================================================
--- gnunet/src/fs/fs_dirmetascan.c      2012-05-24 08:43:24 UTC (rev 21567)
+++ gnunet/src/fs/fs_dirmetascan.c      2012-05-24 09:35:37 UTC (rev 21568)
@@ -248,7 +248,7 @@
  * @param client always NULL
  * @param msg message from the helper process
  */
-static void
+static int
 process_helper_msgs (void *cls, 
                     void *client,
                     const struct GNUNET_MessageHeader *msg)
@@ -281,7 +281,7 @@
     else
       (void) expand_tree (ds->pos,
                          filename, GNUNET_NO);
-    return;
+    return GNUNET_OK;
   case GNUNET_MESSAGE_TYPE_FS_PUBLISH_HELPER_PROGRESS_DIRECTORY:
     if (filename[left-1] != '\0')
     {
@@ -296,7 +296,7 @@
        break;
       }
       ds->pos = ds->pos->parent;
-      return;
+      return GNUNET_OK;
     }
     ds->progress_callback (ds->progress_callback_cls, 
                           filename, GNUNET_YES,
@@ -305,7 +305,7 @@
                           filename, GNUNET_YES);
     if (NULL == ds->toplevel)
       ds->toplevel = ds->pos;
-    return;
+    return GNUNET_OK;
   case GNUNET_MESSAGE_TYPE_FS_PUBLISH_HELPER_ERROR:
     break;
   case GNUNET_MESSAGE_TYPE_FS_PUBLISH_HELPER_SKIP_FILE:
@@ -314,7 +314,7 @@
     ds->progress_callback (ds->progress_callback_cls, 
                           filename, GNUNET_SYSERR,
                           GNUNET_FS_DIRSCANNER_FILE_IGNORED);
-    return;
+    return GNUNET_OK;
   case GNUNET_MESSAGE_TYPE_FS_PUBLISH_HELPER_COUNTING_DONE:
     if (0 != left)
     {
@@ -332,7 +332,7 @@
     ds->pos = ds->toplevel;
     if (GNUNET_YES == ds->pos->is_directory)
       ds->pos = advance (ds->pos);
-    return;
+    return GNUNET_OK;
   case GNUNET_MESSAGE_TYPE_FS_PUBLISH_HELPER_META_DATA:
     {
       size_t nlen;
@@ -382,7 +382,7 @@
       }
       ds->pos->ksk_uri = GNUNET_FS_uri_ksk_create_from_meta_data 
(ds->pos->meta);
       ds->pos = advance (ds->pos);      
-      return;
+      return GNUNET_OK;
     }
   case GNUNET_MESSAGE_TYPE_FS_PUBLISH_HELPER_FINISHED:
     if (NULL != ds->pos)
@@ -402,7 +402,7 @@
     }
     ds->stop_task = GNUNET_SCHEDULER_add_now (&finish_scan,
                                              ds);
-    return;
+    return GNUNET_OK;
   default:
     GNUNET_break (0);
     break;
@@ -410,6 +410,7 @@
   ds->progress_callback (ds->progress_callback_cls, 
                         NULL, GNUNET_SYSERR,
                         GNUNET_FS_DIRSCANNER_INTERNAL_ERROR);
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/statistics/gnunet-service-statistics.c
===================================================================
--- gnunet/src/statistics/gnunet-service-statistics.c   2012-05-24 08:43:24 UTC 
(rev 21567)
+++ gnunet/src/statistics/gnunet-service-statistics.c   2012-05-24 09:35:37 UTC 
(rev 21568)
@@ -214,12 +214,13 @@
  * @param client unused
  * @param msg message to inject
  */
-static void
+static int
 inject_message (void *cls, void *client, const struct GNUNET_MessageHeader 
*msg)
 {
   struct GNUNET_SERVER_Handle *server = cls;
 
   GNUNET_break (GNUNET_OK == GNUNET_SERVER_inject (server, NULL, msg));
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/transport/gnunet-helper-transport-wlan-dummy.c
===================================================================
--- gnunet/src/transport/gnunet-helper-transport-wlan-dummy.c   2012-05-24 
08:43:24 UTC (rev 21567)
+++ gnunet/src/transport/gnunet-helper-transport-wlan-dummy.c   2012-05-24 
09:35:37 UTC (rev 21568)
@@ -119,7 +119,7 @@
  * @param client unused
  * @param hdr inbound message from the FIFO
  */
-static void
+static int
 stdin_send (void *cls, void *client, const struct GNUNET_MessageHeader *hdr)
 {
   struct SendBuffer *write_pout = cls;
@@ -154,6 +154,7 @@
          &in[1],
          payload_size);
   write_pout->size += payload_size;
+  return GNUNET_OK;
 }
 
 
@@ -164,7 +165,7 @@
  * @param client unused
  * @param hdr the message we received to copy to the buffer
  */
-static void
+static int
 file_in_send (void *cls, void *client, const struct GNUNET_MessageHeader *hdr)
 {
   struct SendBuffer *write_std = cls;
@@ -178,6 +179,7 @@
   }
   memcpy (write_std->buf + write_std->size, hdr, sendsize);
   write_std->size += sendsize;
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/transport/gnunet-service-transport.c
===================================================================
--- gnunet/src/transport/gnunet-service-transport.c     2012-05-24 08:43:24 UTC 
(rev 21567)
+++ gnunet/src/transport/gnunet-service-transport.c     2012-05-24 09:35:37 UTC 
(rev 21568)
@@ -230,7 +230,7 @@
   if (NULL == message)
     goto end;
   type = ntohs (message->type);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received Message with type %u from 
peer `%s'\n", type, GNUNET_i2s (peer));
+  GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Received Message with type %u from 
peer `%s'\n", type, GNUNET_i2s (peer));
 
   GNUNET_STATISTICS_update (GST_stats,
                         gettext_noop

Modified: gnunet/src/transport/plugin_transport_http_client.c
===================================================================
--- gnunet/src/transport/plugin_transport_http_client.c 2012-05-24 08:43:24 UTC 
(rev 21567)
+++ gnunet/src/transport/plugin_transport_http_client.c 2012-05-24 09:35:37 UTC 
(rev 21568)
@@ -333,7 +333,7 @@
   return res;
 }
 
-static void
+static int
 client_receive_mst_cb (void *cls, void *client,
                        const struct GNUNET_MessageHeader *message)
 {
@@ -343,7 +343,7 @@
   if (GNUNET_YES != exist_session(p, s))
   {
     GNUNET_break (0);
-    return;
+    return GNUNET_OK;
   }
 
   delay = http_plugin_receive (s, &s->target, message, s, s->addr, s->addrlen);
@@ -359,6 +359,7 @@
                      GNUNET_i2s (&s->target), GNUNET_a2s (s->addr, s->addrlen),
                      delay);
   }
+  return GNUNET_OK;
 }
 
 static void

Modified: gnunet/src/transport/plugin_transport_http_server.c
===================================================================
--- gnunet/src/transport/plugin_transport_http_server.c 2012-05-24 08:43:24 UTC 
(rev 21567)
+++ gnunet/src/transport/plugin_transport_http_server.c 2012-05-24 09:35:37 UTC 
(rev 21568)
@@ -273,7 +273,7 @@
  * @param client clien
  * @param message the message to be forwarded to transport service
  */
-static void
+static int
 server_receive_mst_cb (void *cls, void *client,
                        const struct GNUNET_MessageHeader *message)
 {
@@ -281,7 +281,7 @@
 
   GNUNET_assert (NULL != p);
   if (GNUNET_NO == exist_session(p, s))
-    return;
+    return GNUNET_OK;
 
   struct Plugin *plugin = s->plugin;
   struct GNUNET_TIME_Relative delay;
@@ -299,6 +299,7 @@
                      http_plugin_address_to_string (NULL, s->addr, s->addrlen),
                      delay);
   }
+  return GNUNET_OK;
 }
 
 /**

Modified: gnunet/src/transport/plugin_transport_udp.c
===================================================================
--- gnunet/src/transport/plugin_transport_udp.c 2012-05-24 08:43:24 UTC (rev 
21567)
+++ gnunet/src/transport/plugin_transport_udp.c 2012-05-24 09:35:37 UTC (rev 
21568)
@@ -1263,7 +1263,7 @@
  * @param client the 'struct SourceInformation'
  * @param hdr the actual message
  */
-static void
+static int
 process_inbound_tokenized_messages (void *cls, void *client,
                                     const struct GNUNET_MessageHeader *hdr)
 {
@@ -1274,7 +1274,7 @@
 
   GNUNET_assert (si->session != NULL);
   if (GNUNET_YES == si->session->in_destroy)
-    return; 
+    return GNUNET_OK;
   /* setup ATS */
   ats[0].type = htonl (GNUNET_ATS_QUALITY_NET_DISTANCE);
   ats[0].value = htonl (1);
@@ -1289,6 +1289,7 @@
                 si->arg,
                 si->args);
   si->session->flow_delay_for_other_peer = delay;
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/transport/plugin_transport_udp_broadcasting.c
===================================================================
--- gnunet/src/transport/plugin_transport_udp_broadcasting.c    2012-05-24 
08:43:24 UTC (rev 21567)
+++ gnunet/src/transport/plugin_transport_udp_broadcasting.c    2012-05-24 
09:35:37 UTC (rev 21568)
@@ -90,7 +90,7 @@
 
 
 
-void
+int
 broadcast_ipv6_mst_cb (void *cls, void *client,
                        const struct GNUNET_MessageHeader *message)
 {
@@ -104,7 +104,7 @@
 
   if (GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON !=
       ntohs (msg->header.type))
-    return;
+    return GNUNET_OK;
   LOG (GNUNET_ERROR_TYPE_DEBUG,
        "Received beacon with %u bytes from peer `%s' via address `%s'\n",
        ntohs (msg->header.size), GNUNET_i2s (&msg->sender),
@@ -128,9 +128,10 @@
                             ("# IPv6 multicast HELLO beacons received via 
udp"),
                             1, GNUNET_NO);
   GNUNET_free (mc);
+  return GNUNET_OK;
 }
 
-void
+int
 broadcast_ipv4_mst_cb (void *cls, void *client,
                        const struct GNUNET_MessageHeader *message)
 {
@@ -143,7 +144,7 @@
 
   if (GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON !=
       ntohs (msg->header.type))
-    return;
+    return GNUNET_OK;
   LOG (GNUNET_ERROR_TYPE_DEBUG,
        "Received beacon with %u bytes from peer `%s' via address `%s'\n",
        ntohs (msg->header.size), GNUNET_i2s (&msg->sender),
@@ -168,6 +169,7 @@
                             ("# IPv4 broadcast HELLO beacons received via 
udp"),
                             1, GNUNET_NO);
   GNUNET_free (mc);
+  return GNUNET_OK;
 }
 
 void

Modified: gnunet/src/transport/plugin_transport_wlan.c
===================================================================
--- gnunet/src/transport/plugin_transport_wlan.c        2012-05-24 08:43:24 UTC 
(rev 21567)
+++ gnunet/src/transport/plugin_transport_wlan.c        2012-05-24 09:35:37 UTC 
(rev 21568)
@@ -1081,7 +1081,7 @@
  * @param client pointer to the session this message belongs to
  * @param hdr start of the message
  */
-static void
+static int
 process_data (void *cls, void *client, const struct GNUNET_MessageHeader *hdr)
 {
   struct Plugin *plugin = cls;
@@ -1245,6 +1245,7 @@
                          (mas->endpoint == NULL) ? 0 : sizeof (struct 
GNUNET_TRANSPORT_WLAN_MacAddress));
     break;
   }
+  return GNUNET_OK;
 }
 #undef NUM_ATS
 
@@ -1256,7 +1257,7 @@
  * @param client client that send the data (not used)
  * @param hdr header of the GNUNET_MessageHeader
  */
-static void
+static int
 handle_helper_message (void *cls, void *client,
                       const struct GNUNET_MessageHeader *hdr)
 {
@@ -1358,6 +1359,7 @@
         ntohs (hdr->type), ntohs (hdr->size));
     break;
   }
+  return GNUNET_OK;
 }
 
 

Modified: gnunet/src/vpn/gnunet-service-vpn.c
===================================================================
--- gnunet/src/vpn/gnunet-service-vpn.c 2012-05-24 08:43:24 UTC (rev 21567)
+++ gnunet/src/vpn/gnunet-service-vpn.c 2012-05-24 09:35:37 UTC (rev 21568)
@@ -1504,7 +1504,7 @@
  * @param client NULL
  * @param message message we got from the client (VPN tunnel interface)
  */
-static void
+static int
 message_token (void *cls GNUNET_UNUSED, void *client GNUNET_UNUSED,
                const struct GNUNET_MessageHeader *message)
 {
@@ -1521,7 +1521,7 @@
        (mlen < sizeof (struct GNUNET_MessageHeader) + sizeof (struct 
GNUNET_TUN_Layer2PacketHeader)) )
   {
     GNUNET_break (0);
-    return;
+    return GNUNET_OK;
   }
   tun = (const struct GNUNET_TUN_Layer2PacketHeader *) &message[1];
   mlen -= (sizeof (struct GNUNET_MessageHeader) + sizeof (struct 
GNUNET_TUN_Layer2PacketHeader));
@@ -1535,7 +1535,7 @@
       {
        /* blame kernel */
        GNUNET_break (0);
-       return;
+        return GNUNET_OK;
       }
       pkt6 = (const struct GNUNET_TUN_IPv6Header *) &tun[1];
       get_destination_key_from_ip (AF_INET6,
@@ -1557,7 +1557,7 @@
                               &pkt6->destination_address,
                               buf,
                               sizeof (buf)));
-       return;
+       return GNUNET_OK;
       }
       route_packet (de,
                    AF_INET6,
@@ -1576,7 +1576,7 @@
       {
        /* blame kernel */
        GNUNET_break (0);
-       return;
+       return GNUNET_OK;
       }
       pkt4 = (struct GNUNET_TUN_IPv4Header *) &tun[1];
       get_destination_key_from_ip (AF_INET,
@@ -1598,13 +1598,13 @@
                               &pkt4->destination_address,
                               buf,
                               sizeof (buf)));
-       return;
+        return GNUNET_OK;
       }
       if (pkt4->header_length * 4 != sizeof (struct GNUNET_TUN_IPv4Header))
       {
        GNUNET_log (GNUNET_ERROR_TYPE_INFO,
                    _("Received IPv4 packet with options (dropping it)\n"));    
            
-       return;
+        return GNUNET_OK;
       }
       route_packet (de,
                    AF_INET,
@@ -1621,6 +1621,7 @@
                (unsigned int) ntohs (tun->proto));
     break;
   }
+  return GNUNET_OK;
 }
 
 




reply via email to

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