gnunet-svn
[Top][All Lists]
Advanced

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

[gnunet] branch master updated: fix seti testcase


From: gnunet
Subject: [gnunet] branch master updated: fix seti testcase
Date: Wed, 19 Aug 2020 11:01:52 +0200

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository gnunet.

The following commit(s) were added to refs/heads/master by this push:
     new 5660868ce fix seti testcase
5660868ce is described below

commit 5660868ce7523c4bda8e25954fda0ae2d28a9702
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Wed Aug 19 10:55:36 2020 +0200

    fix seti testcase
---
 src/seti/gnunet-service-seti.c |  6 ++++++
 src/seti/seti_api.c            |  3 ++-
 src/seti/test_seti_api.c       | 12 ++++++++----
 3 files changed, 16 insertions(+), 5 deletions(-)

diff --git a/src/seti/gnunet-service-seti.c b/src/seti/gnunet-service-seti.c
index 618d53128..af478233b 100644
--- a/src/seti/gnunet-service-seti.c
+++ b/src/seti/gnunet-service-seti.c
@@ -2200,6 +2200,9 @@ handle_client_evaluate (void *cls,
                                        UINT32_MAX);
   op->peer = msg->target_peer;
   op->return_intersection = htonl (msg->return_intersection);
+  fprintf (stderr,
+           "Return intersection for evaluate is %d\n",
+           op->return_intersection);
   op->client_request_id = ntohl (msg->request_id);
   context = GNUNET_MQ_extract_nested_mh (msg);
 
@@ -2364,6 +2367,9 @@ handle_client_accept (void *cls,
   listener = op->listener;
   op->listener = NULL;
   op->return_intersection = htonl (msg->return_intersection);
+  fprintf (stderr,
+           "Return intersection for accept is %d\n",
+           op->return_intersection);
   GNUNET_CONTAINER_DLL_remove (listener->op_head,
                                listener->op_tail,
                                op);
diff --git a/src/seti/seti_api.c b/src/seti/seti_api.c
index 337b7b219..5b88b0469 100644
--- a/src/seti/seti_api.c
+++ b/src/seti/seti_api.c
@@ -806,7 +806,8 @@ GNUNET_SETI_accept (struct GNUNET_SETI_Request *request,
     switch (opt->type)
     {
     case GNUNET_SETI_OPTION_RETURN_INTERSECTION:
-      oh->return_intersection = htonl (GNUNET_YES);
+      oh->return_intersection = GNUNET_YES;
+      msg->return_intersection = htonl (GNUNET_YES);
       break;
     default:
       LOG (GNUNET_ERROR_TYPE_ERROR,
diff --git a/src/seti/test_seti_api.c b/src/seti/test_seti_api.c
index 22a3a06e5..9074fab41 100644
--- a/src/seti/test_seti_api.c
+++ b/src/seti/test_seti_api.c
@@ -1,6 +1,6 @@
 /*
      This file is part of GNUnet.
-     Copyright (C) 2012-2014 GNUnet e.V.
+     Copyright (C) 2012-2014, 2020 GNUnet e.V.
 
      GNUnet is free software: you can redistribute it and/or modify it
      under the terms of the GNU Affero General Public License as published
@@ -108,14 +108,18 @@ result_cb_set2 (void *cls,
     break;
   case GNUNET_SETI_STATUS_DONE:
     oh2 = NULL;
-    GNUNET_assert (1 == count);
+    GNUNET_break (1 == count);
+    if (1 != count)
+      ret |= 2;
     GNUNET_SETI_destroy (set2);
     set2 = NULL;
     if (NULL == set1)
       GNUNET_SCHEDULER_shutdown ();
     break;
-  default:
-    GNUNET_assert (0);
+  case GNUNET_SETI_STATUS_DEL_LOCAL:
+    /* unexpected! */
+    ret = 1;
+    break;
   }
 }
 

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

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