guix-env: some update.
[oweals/gnunet.git] / src / cadet / gnunet-cadet-profiler.c
index 65e8f32190ab8de936e029e4c173b05e604d8ce6..15da05b6d4aa529add44b9bbce034cefa6865f74 100644 (file)
@@ -778,7 +778,9 @@ pong_handler (void *cls, struct GNUNET_CADET_Channel *channel,
   latency = GNUNET_TIME_absolute_get_duration (send_time);
   r = ntohl (msg->round_number);
   GNUNET_log (GNUNET_ERROR_TYPE_INFO, "%u <- %u (%u) latency: %s\n",
-              get_index (peer), get_index (peer->dest), ntohl (msg->counter),
+              get_index (peer),
+              get_index (peer->dest),
+              (uint32_t) ntohl (msg->counter),
               GNUNET_STRINGS_relative_time_to_string (latency, GNUNET_NO));
 
   /* Online variance calculation */
@@ -816,7 +818,8 @@ static struct GNUNET_CADET_MessageHandler handlers[] = {
 static void *
 incoming_channel (void *cls, struct GNUNET_CADET_Channel *channel,
                  const struct GNUNET_PeerIdentity *initiator,
-                 uint32_t port, enum GNUNET_CADET_ChannelOption options)
+                 const struct GNUNET_HashCode *port,
+                  enum GNUNET_CADET_ChannelOption options)
 {
   long n = (long) cls;
   struct CadetPeer *peer;
@@ -921,7 +924,7 @@ start_test (void *cls)
     peers[i].dest = select_random_peer (&peers[i]);
     peers[i].ch = GNUNET_CADET_channel_create (peers[i].cadet, NULL,
                                                &peers[i].dest->id,
-                                               1, flags);
+                                               GC_u2h (1), flags);
     if (NULL == peers[i].ch)
     {
       GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Channel %lu failed\n", i);
@@ -966,7 +969,7 @@ warmup (void)
                 i, get_index (peer));
     peers[i].warmup_ch =
       GNUNET_CADET_channel_create (peers[i].cadet, NULL, &peer->id,
-                                  1, GNUNET_CADET_OPTION_DEFAULT);
+                                  GC_u2h (1), GNUNET_CADET_OPTION_DEFAULT);
     if (NULL == peers[i].warmup_ch)
     {
       GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Warmup %u failed\n", i);
@@ -1083,7 +1086,7 @@ tmain (void *cls,
 int
 main (int argc, char *argv[])
 {
-  static uint32_t ports[2];
+  static const struct GNUNET_HashCode *ports[2];
   const char *config_file;
 
   config_file = ".profiler.conf";
@@ -1135,7 +1138,7 @@ main (int argc, char *argv[])
   GNUNET_assert (NULL != ids);
   p_ids = 0;
   test_finished = GNUNET_NO;
-  ports[0] = 1;
+  ports[0] = GC_u2h (1);
   ports[1] = 0;
   GNUNET_CADET_TEST_run ("cadet-profiler", config_file, peers_total,
                         &tmain, NULL, /* tmain cls */