wip
[oweals/gnunet.git] / src / peerinfo / perf_peerinfo_api.c
index fe1851a7ffec985b8ba1fa5d7993607982dc776a..4691570ebd8ef27a44611e6f61633c5038440c70 100755 (executable)
@@ -32,6 +32,7 @@
 #include "gnunet_program_lib.h"
 #include "gnunet_time_lib.h"
 #include "peerinfo.h"
+#include <gauger.h>
 
 #define START_SERVICE 1
 
@@ -107,7 +108,8 @@ add_peer (size_t i)
 static void
 process (void *cls,
          const struct GNUNET_PeerIdentity *peer,
-         const struct GNUNET_HELLO_Message *hello)
+         const struct GNUNET_HELLO_Message *hello,
+         const char * err_msg)
 {
   if (peer == NULL)
     {
@@ -177,6 +179,7 @@ check ()
 #endif
                                  "-c", "test_peerinfo_api_data.conf", NULL);
 #endif
+  GNUNET_assert (NULL != proc);
   GNUNET_PROGRAM_run ((sizeof (argv) / sizeof (char *)) - 1,
                       argv, "perf-peerinfo-api", "nohelp",
                       options, &run, &ok);
@@ -184,6 +187,7 @@ check ()
           "Received %u/%u calls before timeout\n",
           numpeers,
           NUM_REQUESTS * NUM_REQUESTS / 2);
+  GAUGER ("PEERINFO", "Peerinfo lookups", numpeers / 30, "peers/s");
 #if START_SERVICE
   if (0 != GNUNET_OS_process_kill (proc, SIGTERM))
     {