gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r20111 - gnunet/src/namestore


From: gnunet
Subject: [GNUnet-SVN] r20111 - gnunet/src/namestore
Date: Tue, 28 Feb 2012 11:24:37 +0100

Author: wachs
Date: 2012-02-28 11:24:37 +0100 (Tue, 28 Feb 2012)
New Revision: 20111

Modified:
   gnunet/src/namestore/gnunet-service-namestore.c
Log:
- more


Modified: gnunet/src/namestore/gnunet-service-namestore.c
===================================================================
--- gnunet/src/namestore/gnunet-service-namestore.c     2012-02-28 10:24:22 UTC 
(rev 20110)
+++ gnunet/src/namestore/gnunet-service-namestore.c     2012-02-28 10:24:37 UTC 
(rev 20111)
@@ -674,6 +674,35 @@
                           const struct GNUNET_MessageHeader * message)
 {
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received `%s' message\n", 
"ZONE_ITERATION_NEXT");
+
+  struct GNUNET_NAMESTORE_Client *nc;
+  struct GNUNET_NAMESTORE_ZoneIteration *zi;
+  struct ZoneIterationStopMessage * zis_msg = (struct ZoneIterationStopMessage 
*) message;
+  uint32_t id;
+
+  nc = client_lookup(client);
+  if (nc == NULL)
+  {
+    GNUNET_break_op (0);
+    GNUNET_SERVER_receive_done (client, GNUNET_OK);
+    return;
+  }
+
+  id = ntohl (zis_msg->op_id);
+  for (zi = nc->op_head; zi != NULL; zi = zi->next)
+  {
+    if (zi->op_id == id)
+      break;
+  }
+  if (zi == NULL)
+  {
+    GNUNET_break_op (0);
+    GNUNET_SERVER_receive_done (client, GNUNET_OK);
+    return;
+  }
+
+  zi->offset++;
+  res = GSN_database->iterate_records (GSN_database->cls, &zis_msg->zone, 
NULL, zi->offset , &zone_iteration_proc, zi);
 }
 
 




reply via email to

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