fix #3275 with solution from https://gnunet.org/bugs/view.php?id=3275#c8029
[oweals/gnunet.git] / src / hostlist / test_gnunet_daemon_hostlist_learning.c
index b7199637e354fb3dc336fa133e26760b1b5eb57e..f581b532a296892b87ff57b4fb693ca12dcb0675 100644 (file)
@@ -145,7 +145,7 @@ shutdown_testcase ()
   }
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Killing hostlist server ARM process.\n");
-  if (0 != GNUNET_OS_process_kill (adv_peer.arm_proc, SIGTERM))
+  if (0 != GNUNET_OS_process_kill (adv_peer.arm_proc, GNUNET_TERM_SIG))
     GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "kill");
   if (GNUNET_OS_process_wait (adv_peer.arm_proc) != GNUNET_OK)
     GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "waitpid");
@@ -153,7 +153,7 @@ shutdown_testcase ()
   adv_peer.arm_proc = NULL;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Killing hostlist client ARM process.\n");
-  if (0 != GNUNET_OS_process_kill (learn_peer.arm_proc, SIGTERM))
+  if (0 != GNUNET_OS_process_kill (learn_peer.arm_proc, GNUNET_TERM_SIG))
     GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "kill");
   if (GNUNET_OS_process_wait (learn_peer.arm_proc) != GNUNET_OK)
     GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "waitpid");
@@ -313,9 +313,7 @@ check_statistics (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
  */
 static int
 ad_arrive_handler (void *cls, const struct GNUNET_PeerIdentity *peer,
-                   const struct GNUNET_MessageHeader *message,
-                   const struct GNUNET_ATS_Information *atsi,
-                   unsigned int atsi_count)
+                   const struct GNUNET_MessageHeader *message)
 {
   char *hostname;
   char *expected_uri;
@@ -360,7 +358,7 @@ ad_arrive_handler (void *cls, const struct GNUNET_PeerIdentity *peer,
   }
   else
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-                "Expected URI `%s' and recieved URI `%s' differ\n",
+                "Expected URI `%s' and received URI `%s' differ\n",
                 expected_uri, current_adv_uri);
   GNUNET_free (expected_uri);
   GNUNET_free_non_null (hostname);
@@ -423,8 +421,8 @@ setup_adv_peer (struct PeerContext *p, const char *cfgname)
   p->cfg = GNUNET_CONFIGURATION_create ();
   p->arm_proc =
     GNUNET_OS_start_process (GNUNET_YES, GNUNET_OS_INHERIT_STD_OUT_AND_ERR, NULL, NULL, binary,
-                               "gnunet-service-arm",
-                               "-c", cfgname, NULL);
+                            "gnunet-service-arm",
+                            "-c", cfgname, NULL);
   GNUNET_assert (GNUNET_OK == GNUNET_CONFIGURATION_load (p->cfg, cfgname));
   p->stats = GNUNET_STATISTICS_create ("hostlist", p->cfg);
   GNUNET_assert (NULL != p->stats);
@@ -536,4 +534,4 @@ main (int argc, char *argv[])
   return ret;
 }
 
-/* end of test_gnunet_daemon_hostlist.c */
+/* end of test_gnunet_daemon_hostlist_learning.c */