fixing compiler warnings
authorChristian Grothoff <christian@grothoff.org>
Fri, 6 May 2016 14:44:08 +0000 (14:44 +0000)
committerChristian Grothoff <christian@grothoff.org>
Fri, 6 May 2016 14:44:08 +0000 (14:44 +0000)
52 files changed:
po/POTFILES.in
src/ats-tests/ats-testing-log.c
src/ats-tests/ats-testing-preferences.c
src/ats-tests/ats-testing-traffic.c
src/ats-tests/ats-testing.c
src/ats-tests/ats-testing.h
src/ats/gnunet-service-ats_plugins.c
src/cadet/cadet_api.c
src/cadet/gnunet-cadet-profiler.c
src/cadet/gnunet-cadet.c
src/conversation/gnunet-helper-audio-playback.c
src/conversation/gnunet-helper-audio-record.c
src/conversation/gnunet-service-conversation.c
src/core/gnunet-service-core_kx.c
src/core/gnunet-service-core_sessions.c
src/datastore/gnunet-service-datastore.c
src/dht/gnunet-service-dht_clients.c
src/dht/gnunet-service-wdht_clients.c
src/dht/gnunet-service-xdht_clients.c
src/dht/gnunet-service-xdht_neighbours.c
src/dht/gnunet_dht_profiler.c
src/dns/dnsstub.c
src/exit/gnunet-daemon-exit.c
src/fs/fs_download.c
src/fs/fs_namespace.c
src/fs/fs_publish.c
src/fs/gnunet-service-fs_lc.c
src/fs/gnunet-service-fs_push.c
src/gns/gnunet-bcd.c
src/hostlist/gnunet-daemon-hostlist_server.c
src/include/gnunet_common.h
src/nat/nat_auto.c
src/nse/gnunet-service-nse.c
src/peerstore/peerstore_common.c
src/psyc/gnunet-service-psyc.c
src/psycstore/gnunet-service-psycstore.c
src/psycutil/psyc_message.c
src/regex/gnunet-regex-profiler.c
src/regex/regex_block_lib.c
src/rest/gnunet-rest-server.c
src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c
src/scalarproduct/gnunet-service-scalarproduct_bob.c
src/set/gnunet-set-profiler.c
src/statistics/gnunet-service-statistics.c
src/testbed/gnunet-helper-testbed.c
src/testbed/gnunet-service-testbed_peers.c
src/transport/gnunet-service-transport.c
src/transport/gnunet-service-transport_manipulation.c
src/transport/gnunet-service-transport_neighbours.c
src/transport/transport_api_address_to_string.c
src/util/gnunet-scrypt.c
src/vpn/gnunet-service-vpn.c

index f0822c03c860c79de1d3724e36fa03fd663e7a25..d98e3458fd8fb70bc1ed5c38cd065ceb33e9dc3b 100644 (file)
@@ -214,6 +214,10 @@ src/identity-provider/identity_provider_api.c
 src/identity-provider/identity_token.c
 src/identity-provider/plugin_rest_identity_provider.c
 src/jsonapi/jsonapi.c
+src/jsonapi/jsonapi_document.c
+src/jsonapi/jsonapi_error.c
+src/jsonapi/jsonapi_relationship.c
+src/jsonapi/jsonapi_resource.c
 src/json/json.c
 src/json/json_generator.c
 src/json/json_helper.c
@@ -322,6 +326,7 @@ src/set/ibf.c
 src/set/ibf_sim.c
 src/set/set_api.c
 src/social/gnunet-service-social.c
+src/social/gnunet-social.c
 src/social/social_api.c
 src/statistics/gnunet-service-statistics.c
 src/statistics/gnunet-statistics.c
index 5e22d4b47ac41a18f5ef64ab82d50d783fa1b866..87af31f5fe439163cc00c6995fcb9d98d549c05d 100644 (file)
@@ -698,12 +698,13 @@ GNUNET_ATS_TEST_logging_now (struct LoggingHandle *l)
     if (GNUNET_YES == l->verbose)
     {
       GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-          "Master[%u] delta: %llu us, bytes (sent/received): %u / %u; throughput send/recv: %u / %u\n", c_m,
-          delta.rel_value_us,
-          mlt->total_bytes_sent,
-          mlt->total_bytes_received,
-          mlt->total_throughput_send,
-          mlt->total_throughput_recv);
+                  "Master[%u] delta: %llu us, bytes (sent/received): %u / %u; throughput send/recv: %u / %u\n",
+                  c_m,
+                  (unsigned long long) delta.rel_value_us,
+                  mlt->total_bytes_sent,
+                  mlt->total_bytes_received,
+                  mlt->total_throughput_send,
+                  mlt->total_throughput_recv);
     }
 
     mlt->slaves_log = GNUNET_malloc (bp->peer->num_partners *
@@ -783,13 +784,13 @@ GNUNET_ATS_TEST_logging_now (struct LoggingHandle *l)
       if (GNUNET_YES == l->verbose)
       {
         GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-            "Master [%u] -> Slave [%u]: delta: %llu us, bytes (sent/received): %u / %u; throughput send/recv: %u / %u\n",
-            c_m, c_s,
-            delta.rel_value_us,
-            mlt->total_bytes_sent,
-            mlt->total_bytes_received,
-            slt->throughput_sent,
-            slt->throughput_recv);
+                    "Master [%u] -> Slave [%u]: delta: %llu us, bytes (sent/received): %u / %u; throughput send/recv: %u / %u\n",
+                    c_m, c_s,
+                    (unsigned long long) delta.rel_value_us,
+                    mlt->total_bytes_sent,
+                    mlt->total_bytes_received,
+                    slt->throughput_sent,
+                    slt->throughput_recv);
       }
       else
         GNUNET_log(GNUNET_ERROR_TYPE_DEBUG,
index 856c8de4b4cea8333ac0602d36be1752316b6181..256fa844b6fb60877d9ca99c06b9540943cc424b 100644 (file)
@@ -143,13 +143,13 @@ set_pref_task (void *cls)
  */
 struct PreferenceGenerator *
 GNUNET_ATS_TEST_generate_preferences_start (struct BenchmarkPeer *src,
-    struct BenchmarkPartner *dest,
-    enum GeneratorType type,
-    long int base_value,
-    long int value_rate,
-    struct GNUNET_TIME_Relative period,
-    struct GNUNET_TIME_Relative frequency,
-    enum GNUNET_ATS_PreferenceKind kind)
+                                            struct BenchmarkPartner *dest,
+                                            enum GeneratorType type,
+                                            unsigned int base_value,
+                                            unsigned int value_rate,
+                                            struct GNUNET_TIME_Relative period,
+                                            struct GNUNET_TIME_Relative frequency,
+                                            enum GNUNET_ATS_PreferenceKind kind)
 {
   struct PreferenceGenerator *pg;
 
@@ -174,31 +174,31 @@ GNUNET_ATS_TEST_generate_preferences_start (struct BenchmarkPeer *src,
   switch (type) {
     case GNUNET_ATS_TEST_TG_CONSTANT:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up constant preference generator master[%u] `%s' and slave [%u] `%s' max %u Bips\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_value);
+                  "Setting up constant preference generator master[%u] `%s' and slave [%u] `%s' max %u Bips\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_value);
       break;
     case GNUNET_ATS_TEST_TG_LINEAR:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up linear preference generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bips\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_value, value_rate);
+                  "Setting up linear preference generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bips\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_value, value_rate);
       break;
     case GNUNET_ATS_TEST_TG_SINUS:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up sinus preference generator master[%u] `%s' and slave [%u] `%s' baserate %u Bips, amplitude %u Bps\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_value, value_rate);
+                  "Setting up sinus preference generator master[%u] `%s' and slave [%u] `%s' baserate %u Bips, amplitude %u Bps\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_value, value_rate);
       break;
     case GNUNET_ATS_TEST_TG_RANDOM:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up random preference generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bps\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_value, value_rate);
+                  "Setting up random preference generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bps\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_value, value_rate);
       break;
     default:
       break;
index 5eb01bd559e846312fa53bed6a0bfad875e830ca..f0bab73672eb6ca7447fc2b11fba2c8d3f46ed11 100644 (file)
@@ -93,8 +93,9 @@ get_delay (struct TrafficGenerator *tg)
   delay.rel_value_us =  GNUNET_TIME_UNIT_SECONDS.rel_value_us * TEST_MESSAGE_SIZE / cur_rate;
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-      "Current rate is %u, calculated delay is %u \n",
-      cur_rate, delay.rel_value_us);
+              "Current rate is %lld, calculated delay is %llu\n",
+              cur_rate,
+              (unsigned long long) delay.rel_value_us);
   return delay;
 }
 
@@ -308,12 +309,12 @@ GNUNET_ATS_TEST_traffic_handle_pong (struct BenchmarkPartner *p)
  */
 struct TrafficGenerator *
 GNUNET_ATS_TEST_generate_traffic_start (struct BenchmarkPeer *src,
-    struct BenchmarkPartner *dest,
-    enum GeneratorType type,
-    long int base_rate,
-    long int max_rate,
-    struct GNUNET_TIME_Relative period,
-    struct GNUNET_TIME_Relative duration)
+                                        struct BenchmarkPartner *dest,
+                                        enum GeneratorType type,
+                                        unsigned int base_rate,
+                                        unsigned int max_rate,
+                                        struct GNUNET_TIME_Relative period,
+                                        struct GNUNET_TIME_Relative duration)
 {
   struct TrafficGenerator *tg;
 
@@ -337,31 +338,32 @@ GNUNET_ATS_TEST_generate_traffic_start (struct BenchmarkPeer *src,
   switch (type) {
     case GNUNET_ATS_TEST_TG_CONSTANT:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up constant traffic generator master[%u] `%s' and slave [%u] `%s' max %u Bips\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_rate);
+                  "Setting up constant traffic generator master[%u] `%s' and slave [%u] `%s' max %u Bips\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_rate);
       break;
     case GNUNET_ATS_TEST_TG_LINEAR:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up linear traffic generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bips\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_rate, max_rate);
+                  "Setting up linear traffic generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bips\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_rate,
+                  max_rate);
       break;
     case GNUNET_ATS_TEST_TG_SINUS:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up sinus traffic generator master[%u] `%s' and slave [%u] `%s' baserate %u Bips, amplitude %u Bps\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_rate, max_rate);
+                  "Setting up sinus traffic generator master[%u] `%s' and slave [%u] `%s' baserate %u Bips, amplitude %u Bps\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_rate, max_rate);
       break;
     case GNUNET_ATS_TEST_TG_RANDOM:
       GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-          "Setting up random traffic generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bps\n",
-          dest->me->no, GNUNET_i2s (&dest->me->id),
-          dest->dest->no, GNUNET_i2s (&dest->dest->id),
-          base_rate, max_rate);
+                  "Setting up random traffic generator master[%u] `%s' and slave [%u] `%s' min %u Bips max %u Bps\n",
+                  dest->me->no, GNUNET_i2s (&dest->me->id),
+                  dest->dest->no, GNUNET_i2s (&dest->dest->id),
+                  base_rate, max_rate);
       break;
     default:
       break;
index 49aa5a052e3403b4330a3c5ac32c010385047c01..24d46442450a7e3d0a8e876f714047db5991d8ec 100644 (file)
@@ -243,8 +243,9 @@ comm_connect_cb (void *cls, const struct GNUNET_PeerIdentity * peer)
 
     if (me->core_slave_connections == top->num_slaves)
     {
-      GNUNET_log(GNUNET_ERROR_TYPE_INFO, "Master [%u] connected all slaves\n",
-          me->no);
+      GNUNET_log(GNUNET_ERROR_TYPE_INFO,
+                 "Master [%u] connected all slaves\n",
+                 me->no);
     }
     completed = GNUNET_YES;
     for (c = 0; c < top->num_masters; c++)
@@ -254,9 +255,8 @@ comm_connect_cb (void *cls, const struct GNUNET_PeerIdentity * peer)
     }
     if (GNUNET_YES == completed)
     {
-      GNUNET_log(GNUNET_ERROR_TYPE_INFO,
-          "All master peers connected all slave peers\n", id,
-          GNUNET_i2s (peer));
+      GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                  "All master peers connected all slave peers\n");
       top->state.connected_CORE = GNUNET_YES;
       /* Notify about setup done */
       if (NULL != top->done_cb)
index f0770d6aeb83dbb09d03e609b18d92d7d3220371..74da0f78cf02be63cd1b5248af4f721652383409 100644 (file)
@@ -591,12 +591,13 @@ GNUNET_ATS_TEST_traffic_handle_pong (struct BenchmarkPartner *p);
  */
 struct TrafficGenerator *
 GNUNET_ATS_TEST_generate_traffic_start (struct BenchmarkPeer *src,
-    struct BenchmarkPartner *dest,
-    enum GeneratorType type,
-    long int base_rate,
-    long int max_rate,
-    struct GNUNET_TIME_Relative period,
-    struct GNUNET_TIME_Relative duration);
+                                        struct BenchmarkPartner *dest,
+                                        enum GeneratorType type,
+                                        unsigned int base_rate,
+                                        unsigned int max_rate,
+                                        struct GNUNET_TIME_Relative period,
+                                        struct GNUNET_TIME_Relative duration);
+
 
 void
 GNUNET_ATS_TEST_generate_traffic_stop (struct TrafficGenerator *tg);
@@ -623,13 +624,13 @@ GNUNET_ATS_TEST_generate_traffic_stop_all ();
  */
 struct PreferenceGenerator *
 GNUNET_ATS_TEST_generate_preferences_start (struct BenchmarkPeer *src,
-    struct BenchmarkPartner *dest,
-    enum GeneratorType type,
-    long int base_value,
-    long int value_rate,
-    struct GNUNET_TIME_Relative period,
-    struct GNUNET_TIME_Relative frequency,
-    enum GNUNET_ATS_PreferenceKind kind);
+                                            struct BenchmarkPartner *dest,
+                                            enum GeneratorType type,
+                                            unsigned int base_value,
+                                            unsigned int value_rate,
+                                            struct GNUNET_TIME_Relative period,
+                                            struct GNUNET_TIME_Relative frequency,
+                                            enum GNUNET_ATS_PreferenceKind kind);
 
 void
 GNUNET_ATS_TEST_generate_preferences_stop (struct PreferenceGenerator *pg);
index a753d6a8c216efc6026af50de626ec5db603b99a..c2388e28b6affe25a97c54f635587677193d445a 100644 (file)
@@ -132,8 +132,7 @@ solver_info_cb (void *cls,
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                 "Solver notifies `%s' with result `%s'\n",
                 "GAS_OP_SOLVE_STOP",
-                (GAS_STAT_SUCCESS == status) ? "SUCCESS" : "FAIL",
-                add_info);
+                (GAS_STAT_SUCCESS == status) ? "SUCCESS" : "FAIL");
     return;
   case GAS_OP_SOLVE_SETUP_START:
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
@@ -306,7 +305,7 @@ parse_quota (const char *quota_str,
                 direction,
                 GNUNET_ATS_print_network_type (network),
                 quota_str,
-                GNUNET_ATS_DefaultBandwidth);
+                (unsigned long long) GNUNET_ATS_DefaultBandwidth);
     ret = GNUNET_ATS_DefaultBandwidth;
   }
   else
@@ -360,7 +359,7 @@ load_quota (const struct GNUNET_CONFIGURATION_Handle *cfg,
                 _("No %s-quota configured for network `%s', assigning default bandwidth %llu\n"),
                 direction,
                 GNUNET_ATS_print_network_type (type),
-                GNUNET_ATS_DefaultBandwidth);
+                (unsigned long long) GNUNET_ATS_DefaultBandwidth);
     ret = GNUNET_ATS_DefaultBandwidth;
   }
   GNUNET_free (entry);
index d5b0688e633b085c04c588a216c896af3e807d84..960f4788c2321a3730f46d35cc704125cd925b10 100644 (file)
@@ -1105,7 +1105,10 @@ process_get_peer (struct GNUNET_CADET_Handle *h,
   if (msize != esize)
   {
     GNUNET_break_op (0);
-    GNUNET_log (GNUNET_ERROR_TYPE_WARNING, "m:%u, e: %u\n", msize, esize);
+    GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
+                "m:%u, e: %u\n",
+                (unsigned int) msize,
+                (unsigned int) esize);
     h->info_cb.peer_cb (h->info_cls, NULL, 0, 0, 0, NULL);
     goto clean_cls;
   }
@@ -1212,11 +1215,17 @@ process_get_tunnel (struct GNUNET_CADET_Handle *h,
   if (msize != esize)
   {
     GNUNET_break_op (0);
-    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "m:%u, e: %u (%u ch, %u conn)\n",
-                msize, esize, ch_n, c_n);
-    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "%u (%u ch, %u conn)\n",
-                sizeof (struct GNUNET_CADET_LocalInfoTunnel),
-                sizeof (CADET_ChannelNumber), sizeof (struct GNUNET_HashCode));
+    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                "m:%u, e: %u (%u ch, %u conn)\n",
+                (unsigned int) msize,
+                (unsigned int) esize,
+                ch_n,
+                c_n);
+    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                "%u (%u ch, %u conn)\n",
+                (unsigned int) sizeof (struct GNUNET_CADET_LocalInfoTunnel),
+                (unsigned int) sizeof (CADET_ChannelNumber),
+                (unsigned int) sizeof (struct GNUNET_HashCode));
     h->info_cb.tunnel_cb (h->info_cls, NULL, 0, 0, NULL, NULL, 0, 0);
     goto clean_cls;
   }
index b2a07cb0c0814eb0e807df2e3fb190e51487625c..aa095d190f6e845ebe718360d2f4f0b341fe6882 100644 (file)
@@ -453,8 +453,10 @@ stats_iterator (void *cls,
   uint32_t i;
 
   i = GNUNET_TESTBED_get_index (peer);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, " STATS %u - %s [%s]: %llu\n",
-              i, subsystem, name, value);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              " STATS %u - %s [%s]: %llu\n",
+              i, subsystem, name,
+              (unsigned long long) value);
 
   return GNUNET_OK;
 }
@@ -569,7 +571,9 @@ adjust_running_peers (unsigned int target)
 static void
 next_rnd (void *cls)
 {
-  GNUNET_log (GNUNET_ERROR_TYPE_INFO, "ROUND %ld\n", current_round);
+  GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+              "ROUND %u\n",
+              current_round);
   if (0.0 == rounds[current_round])
   {
     GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Finishing\n");
@@ -680,7 +684,7 @@ pong (struct GNUNET_CADET_Channel *channel,
 static size_t
 tmt_rdy_ping (void *cls, size_t size, void *buf)
 {
-  struct CadetPeer *peer = (struct CadetPeer *) cls;
+  struct CadetPeer *peer = cls;
   struct CadetPingMessage *msg = buf;
 
   peer->ping_ntr = NULL;
@@ -691,11 +695,16 @@ tmt_rdy_ping (void *cls, size_t size, void *buf)
     GNUNET_break (GNUNET_YES == test_finished);
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                 "size %u, buf %p, data_sent %u, data_received %u\n",
-                size, buf, peer->data_sent, peer->data_received);
+                (unsigned int) size,
+                buf,
+                peer->data_sent,
+                peer->data_received);
 
     return 0;
   }
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Sending: msg %d\n", peer->data_sent);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "Sending: msg %d\n",
+              peer->data_sent);
   msg->header.size = htons (size);
   msg->header.type = htons (PING);
   msg->counter = htonl (peer->data_sent++);
@@ -726,7 +735,9 @@ ping_handler (void *cls, struct GNUNET_CADET_Channel *channel,
 {
   long n = (long) cls;
 
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "%u got PING\n", n);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "%u got PING\n",
+              (unsigned int) n);
   GNUNET_CADET_receive_done (channel);
   if (GNUNET_NO == test_finished)
     pong (channel, (struct CadetPingMessage *) message);
@@ -814,8 +825,11 @@ incoming_channel (void *cls, struct GNUNET_CADET_Channel *channel,
   GNUNET_assert (NULL != peer);
   if (NULL == peers[n].incoming)
   {
-    GNUNET_log (GNUNET_ERROR_TYPE_INFO, "WARMUP %3u: %u <= %u\n",
-                peers_warmup, n, get_index (peer));
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "WARMUP %3u: %u <= %u\n",
+                peers_warmup,
+                (unsigned int) n,
+                get_index (peer));
     peers_warmup++;
     if (peers_warmup < peers_total)
       return NULL;
@@ -829,8 +843,11 @@ incoming_channel (void *cls, struct GNUNET_CADET_Channel *channel,
   }
   GNUNET_assert (peer == peers[n].incoming);
   GNUNET_assert (peer->dest == &peers[n]);
-  GNUNET_log (GNUNET_ERROR_TYPE_INFO, "%u <= %u %p\n",
-              n, get_index (peer), channel);
+  GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+              "%u <= %u %p\n",
+              (unsigned int) n,
+              get_index (peer),
+              channel);
   peers[n].incoming_ch = channel;
 
   return NULL;
@@ -911,8 +928,11 @@ start_test (void *cls)
       GNUNET_CADET_TEST_cleanup (test_ctx);
       return;
     }
-    GNUNET_log (GNUNET_ERROR_TYPE_INFO, "%u => %u %p\n",
-                i, get_index (peers[i].dest), peers[i].ch);
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "%lu => %u %p\n",
+                i,
+                get_index (peers[i].dest),
+                peers[i].ch);
     peers[i].ping_task = GNUNET_SCHEDULER_add_delayed (delay_ms_rnd (2000),
                                                        &ping, &peers[i]);
   }
@@ -981,8 +1001,10 @@ peer_id_cb (void *cls,
     return;
   }
   peers[n].id = *(pinfo->result.id);
-  GNUNET_log (GNUNET_ERROR_TYPE_INFO, " %u  id: %s\n",
-              n, GNUNET_i2s (&peers[n].id));
+  GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+              "%ld  id: %s\n",
+              n,
+              GNUNET_i2s (&peers[n].id));
   GNUNET_break (GNUNET_OK ==
                 GNUNET_CONTAINER_multipeermap_put (ids, &peers[n].id, &peers[n],
                                                    GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST));
index 6453392d85cea8950fa9f5aaf343e7d6b58358eb..f24975203e7e0227383d38eb0603f8314214919e 100644 (file)
@@ -266,7 +266,9 @@ data_ready (void *cls, size_t size, void *buf)
   }
 
   total_size = data_size + sizeof (struct GNUNET_MessageHeader);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "sending %u bytes\n", data_size);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "sending %u bytes\n",
+              (unsigned int) data_size);
   GNUNET_assert (size >= total_size);
 
   msg = buf;
@@ -297,7 +299,9 @@ read_stdio (void *cls)
   static char buf[60000];
 
   data_size = read (0, buf, 60000);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "stdio read %u bytes\n", data_size);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "stdio read %u bytes\n",
+              (unsigned int) data_size);
   if (data_size < 1)
   {
     GNUNET_SCHEDULER_shutdown();
index 7b9589181630f4cbfe43b2ff508848a3c1b36269..77529e3b509124cb002dd15334067ee0077a4fbf 100644 (file)
@@ -173,15 +173,15 @@ process_header (ogg_packet *op)
   dec = opus_decoder_create (SAMPLING_RATE, channels, &err);
   if (OPUS_OK != err)
   {
-    fprintf (stderr, 
-            "Cannot create encoder: %s\n", 
+    fprintf (stderr,
+            "Cannot create encoder: %s\n",
             opus_strerror (err));
     return NULL;
   }
   if (! dec)
   {
     fprintf (stderr,
-            "Decoder initialization failed: %s\n", 
+            "Decoder initialization failed: %s\n",
             opus_strerror (err));
     return NULL;
   }
@@ -209,7 +209,7 @@ process_header (ogg_packet *op)
 
 
 #ifdef DEBUG_DUMP_DECODED_OGG
-static size_t 
+static size_t
 fwrite_le32(opus_int32 i32, FILE *file)
 {
    unsigned char buf[4];
@@ -221,7 +221,7 @@ fwrite_le32(opus_int32 i32, FILE *file)
 }
 
 
-static size_t 
+static size_t
 fwrite_le16(int i16, FILE *file)
 {
    unsigned char buf[2];
@@ -292,9 +292,11 @@ audio_write (int64_t maxout)
       int64_t wrote = 0;
       wrote = to_write;
       GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-                  "Writing %u * %u * %u = %u bytes into PA\n",
-                  to_write, channels, sizeof (float),
-                  to_write * channels * sizeof (float));
+                  "Writing %u * %u * %u = %llu bytes into PA\n",
+                  to_write,
+                  channels,
+                  (unsigned int) sizeof (float),
+                  (unsigned long long) (to_write * channels * sizeof (float)));
 #ifdef DEBUG_DUMP_DECODED_OGG
       if (dump_to_stdout)
       {
@@ -453,12 +455,14 @@ ogg_demux_and_decode ()
           so that we can adjust the timestamp counting.*/
         gran_offset = preskip;
 
-        if (!pcm_buffer)
+        if (! pcm_buffer)
         {
           GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-                  "Allocating %u * %u * %u = %u bytes of buffer space\n",
-                  MAX_FRAME_SIZE, channels, sizeof (float),
-                  MAX_FRAME_SIZE * channels * sizeof (float));
+                      "Allocating %u * %u * %u = %llu bytes of buffer space\n",
+                      MAX_FRAME_SIZE,
+                      channels,
+                      (unsigned int) sizeof (float),
+                      (unsigned long long) (MAX_FRAME_SIZE * channels * sizeof (float)));
           pcm_buffer = pa_xmalloc (sizeof (float) * MAX_FRAME_SIZE * channels);
         }
       }
@@ -501,7 +505,9 @@ ogg_demux_and_decode ()
         frame_size = ret;
         GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                     "Decoded %d bytes/channel (%d bytes) from %u compressed bytes\n",
-                    ret, ret * channels, op.bytes);
+                    ret,
+                    ret * channels,
+                    (unsigned int) op.bytes);
 
         /*Apply header gain, if we're not using an opus library new
           enough to do this internally.*/
index 31943810fc1594992a1f381de6355c47662ea426..73f4cfda3af20daa67e9d582637029bca1da1115 100644 (file)
@@ -405,8 +405,8 @@ stream_read_callback (pa_stream * s,
   const void *data;
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-             "Got %u/%u bytes of PCM data\n",
-             length,
+             "Got %u/%d bytes of PCM data\n",
+             (unsigned int) length,
              pcm_length);
 
   GNUNET_assert (NULL != s);
@@ -718,8 +718,8 @@ ogg_init ()
     if (NULL == commentspacket)
     {
       GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-                 _("Failed to allocate %d bytes for second packet\n"),
-                  commentspacket_len);
+                 _("Failed to allocate %u bytes for second packet\n"),
+                  (unsigned int) commentspacket_len);
       exit (5);
     }
 
index 10f169105391540a718c5fc7aa3e53be5a25ce91..d12fbdc56606fd74a9cf82945b3841f47a122515 100644 (file)
@@ -779,7 +779,9 @@ transmit_line_audio (void *cls,
   ch->audio_data = NULL;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Sending %u bytes of audio data from line %u to remote line %u via cadet\n",
-              ch->audio_size, ch->line->local_line, ch->remote_line);
+              (unsigned int) ch->audio_size,
+              ch->line->local_line,
+              ch->remote_line);
   return sizeof (struct CadetAudioMessage) + ch->audio_size;
 }
 
@@ -1291,21 +1293,25 @@ handle_cadet_audio_message (void *cls,
     {
       GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                   "Received %u bytes of AUDIO data for non-existing line %u, dropping.\n",
-                  msize, ntohl (msg->remote_line));
+                  (unsigned int) msize,
+                  ntohl (msg->remote_line));
       return GNUNET_SYSERR;
     }
     if (NULL == ch)
     {
       GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                   "Received %u bytes of AUDIO data for unknown sender.\n",
-                  msize);
+                  (unsigned int) msize);
       return GNUNET_SYSERR;
     }
     if ((GNUNET_YES == ch->suspended_local) || (GNUNET_YES == ch->suspended_remote))
     {
       GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                   "Received %u bytes of AUDIO data on suspended channel CID %u:(%u:%u); dropping\n",
-                  msize, ch->cid, ch->remote_line, line->local_line);
+                  (unsigned int) msize,
+                  ch->cid,
+                  ch->remote_line,
+                  line->local_line);
       GNUNET_CADET_receive_done (channel);
       return GNUNET_OK;
     }
@@ -1315,7 +1321,10 @@ handle_cadet_audio_message (void *cls,
   GNUNET_CADET_receive_done (channel);
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Forwarding %u bytes of AUDIO data to client CID %u:(%u:%u)\n",
-              msize, ch->cid, ch->remote_line, ch->line->local_line);
+              (unsigned int) msize,
+              ch->cid,
+              ch->remote_line,
+              ch->line->local_line);
   cam = (struct ClientAudioMessage *) buf;
   cam->header.size = htons (sizeof (buf));
   cam->header.type = htons (GNUNET_MESSAGE_TYPE_CONVERSATION_CS_AUDIO);
index 9bb5af100720928cda164ad6fd10389206ee2fe6..6a1924e5409b327b3deb842d6360cd050a3c9405 100644 (file)
@@ -916,9 +916,9 @@ GSC_KX_handle_ephemeral_key (struct GSC_KeyExchangeInfo *kx,
     GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
                _("Ephemeral key message from peer `%s' rejected as its validity range does not match our system time (%llu not in [%llu,%llu]).\n"),
                GNUNET_i2s (&kx->peer),
-               now.abs_value_us,
-               start_t.abs_value_us,
-               end_t.abs_value_us);
+               (unsigned long long) now.abs_value_us,
+                (unsigned long long) start_t.abs_value_us,
+                (unsigned long long) end_t.abs_value_us);
     return;
   }
   kx->other_ephemeral_key = m->ephemeral_key;
@@ -1395,7 +1395,7 @@ GSC_KX_encrypt_and_transmit (struct GSC_KeyExchangeInfo *kx,
                              used - ENCRYPTED_HEADER_SIZE));
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Encrypted %u bytes for %s\n",
-              used - ENCRYPTED_HEADER_SIZE,
+              (unsigned int) (used - ENCRYPTED_HEADER_SIZE),
               GNUNET_i2s (&kx->peer));
   derive_auth_key (&auth_key,
                   &kx->encrypt_key,
@@ -1517,7 +1517,7 @@ GSC_KX_handle_encrypted_message (struct GSC_KeyExchangeInfo *kx,
     return;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Decrypted %u bytes from %s\n",
-              size - ENCRYPTED_HEADER_SIZE,
+              (unsigned int) (size - ENCRYPTED_HEADER_SIZE),
               GNUNET_i2s (&kx->peer));
   pt = (struct EncryptedMessage *) buf;
 
index 890499394b29efcbdd0f430897aede8be1aaa039..0a547be1b24ad5a201b0516964c8256de79f64ee 100644 (file)
@@ -706,7 +706,7 @@ try_transmission (struct Session *session)
                 "Soliciting messages (excess %d, maxpc %d, message size %u, deadline %s)\n",
                 excess,
                 maxpc,
-                msize,
+                (unsigned int) msize,
                 GNUNET_STRINGS_relative_time_to_string (GNUNET_TIME_absolute_get_remaining (min_deadline),
                                                         GNUNET_YES));
     solicit_messages (session,
index 6ebfba7fc91b713ab5dcbbcb94451196fa2e6dd6..64c3640ad8cb6cca582bff9b09c39521898496ee 100644 (file)
@@ -1400,7 +1400,8 @@ process_stat_in (void *cls,
   payload += value;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Notification from statistics about existing payload (%llu), new payload is %llu\n",
-              value, payload);
+              (unsigned long long) value,
+              (unsigned long long) payload);
   return GNUNET_OK;
 }
 
index a5757c25a33c2732c28c806de07d00a761d75d54..942bf578549920babee3b554806aa45ab32834b8 100644 (file)
@@ -926,13 +926,18 @@ send_reply_to_client (void *cls, size_t size, void *buf)
                                  reply);
     memcpy (&cbuf[off], reply->msg, msize);
     GNUNET_free (reply);
-    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Transmitting %u bytes to client %p\n",
-                msize, client->client_handle);
+    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                "Transmitting %u bytes to client %p\n",
+                (unsigned int) msize,
+                client->client_handle);
     off += msize;
   }
   process_pending_messages (client);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Transmitted %u/%u bytes to client %p\n",
-              (unsigned int) off, (unsigned int) size, client->client_handle);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "Transmitted %u/%u bytes to client %p\n",
+              (unsigned int) off,
+              (unsigned int) size,
+              client->client_handle);
   return off;
 }
 
index 8eb114660fe4e449cef5f52cfc3a177cef05a0f0..3d2eba460d1a1258a20cd0750f670df1163bf8af 100644 (file)
@@ -318,13 +318,18 @@ send_reply_to_client (void *cls, size_t size, void *buf)
                                  reply);
     memcpy (&cbuf[off], reply->msg, msize);
     GNUNET_free (reply);
-    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Transmitting %u bytes to client %p\n",
-                msize, client->client_handle);
+    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                "Transmitting %u bytes to client %p\n",
+                (unsigned int) msize,
+                client->client_handle);
     off += msize;
   }
   process_pending_messages (client);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Transmitted %u/%u bytes to client %p\n",
-              (unsigned int) off, (unsigned int) size, client->client_handle);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "Transmitted %u/%u bytes to client %p\n",
+              (unsigned int) off,
+              (unsigned int) size,
+              client->client_handle);
   return off;
 }
 
index 3475d00c969cc0b4f6e70e60eecb4fce502ce6a2..bc5504ebe07ce600b37b85e06c7d6154b231dd3e 100644 (file)
@@ -318,13 +318,18 @@ send_reply_to_client (void *cls, size_t size, void *buf)
                                  reply);
     memcpy (&cbuf[off], reply->msg, msize);
     GNUNET_free (reply);
-    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Transmitting %u bytes to client %p\n",
-                msize, client->client_handle);
+    GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                "Transmitting %u bytes to client %p\n",
+                (unsigned int) msize,
+                client->client_handle);
     off += msize;
   }
   process_pending_messages (client);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Transmitted %u/%u bytes to client %p\n",
-              (unsigned int) off, (unsigned int) size, client->client_handle);
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "Transmitted %u/%u bytes to client %p\n",
+              (unsigned int) off,
+              (unsigned int) size,
+              client->client_handle);
   return off;
 }
 
index c6de94a5a4882323308a698a5ecd577599d021d0..6f3137f8a4b47d90b4191757558930ae7f27b29b 100644 (file)
@@ -3309,8 +3309,10 @@ send_verify_successor_message (void *cls)
   trail_id = trail->trail_id;
   if (NULL == GDS_ROUTING_get_next_hop(trail_id,GDS_ROUTING_SRC_TO_DEST))
   {
-    DEBUG(" NO ENTRY FOUND IN %s ROUTING TABLE for trail id %s, line",
-            GNUNET_i2s(&my_identity), GNUNET_h2s(&trail->trail_id), __LINE__);
+    DEBUG(" NO ENTRY FOUND IN %s ROUTING TABLE for trail id %s, line %u",
+          GNUNET_i2s (&my_identity),
+          GNUNET_h2s (&trail->trail_id),
+          __LINE__);
     GNUNET_break(0);
     return;
   }
@@ -5352,8 +5354,10 @@ handle_dht_p2p_verify_successor_result(void *cls,
   {
     /* Here it may happen that source peer has found a new successor, and removed
      the trail, Hence no entry found in the routing table. Fail silently.*/
-    DEBUG(" NO ENTRY FOUND IN %s ROUTING TABLE for trail id %s, line",
-            GNUNET_i2s(&my_identity), GNUNET_h2s(&trail_id), __LINE__);
+    DEBUG (" NO ENTRY FOUND IN %s ROUTING TABLE for trail id %s, line %u",
+           GNUNET_i2s (&my_identity),
+           GNUNET_h2s (&trail_id),
+           __LINE__);
     GNUNET_break_op(0);
     return GNUNET_OK;
   }
@@ -5773,8 +5777,10 @@ handle_dht_p2p_trail_teardown (void *cls, const struct GNUNET_PeerIdentity *peer
   next_hop = GDS_ROUTING_get_next_hop (trail_id, trail_direction);
   if (NULL == next_hop)
   {
-    DEBUG(" NO ENTRY FOUND IN %s ROUTING TABLE for trail id %s, line",
-            GNUNET_i2s(&my_identity), GNUNET_h2s(&trail_id), __LINE__);
+    DEBUG(" NO ENTRY FOUND IN %s ROUTING TABLE for trail id %s, line %u",
+          GNUNET_i2s (&my_identity),
+          GNUNET_h2s(&trail_id),
+          __LINE__);
     GNUNET_break (0);
     return GNUNET_SYSERR;
   }
index 03ea62152960755f11fce5b84c7d33ebef4f705f..065ea5d1bd9d2e406e58b648eb29aa99db239f65 100644 (file)
@@ -494,8 +494,10 @@ bandwidth_stats_cont (void *cls,
                       struct GNUNET_TESTBED_Operation *op,
                       const char *emsg)
 {
-  INFO ("# Outgoing bandwidth: %u\n", outgoing_bandwidth);
-  INFO ("# Incoming bandwidth: %u\n", incoming_bandwidth);
+  INFO ("# Outgoing bandwidth: %llu\n",
+        (unsigned long long) outgoing_bandwidth);
+  INFO ("# Incoming bandwidth: %llu\n",
+        (unsigned long long) incoming_bandwidth);
   GNUNET_SCHEDULER_shutdown ();
 }
 
@@ -508,8 +510,8 @@ bandwidth_stats_cont (void *cls,
  * @param subsystem name of subsystem that created the statistic
  * @param name the name of the datum
  * @param value the current value
- * @param is_persistent GNUNET_YES if the value is persistent, GNUNET_NO if not
- * @return GNUNET_OK to continue, GNUNET_SYSERR to abort iteration
+ * @param is_persistent #GNUNET_YES if the value is persistent, #GNUNET_NO if not
+ * @return #GNUNET_OK to continue, #GNUNET_SYSERR to abort iteration
  */
 static int
 bandwidth_stats_iterator (void *cls,
@@ -635,7 +637,8 @@ get_iter (void *cls,
 
   total_put_path_length = total_put_path_length + (double)put_path_length;
   total_get_path_length = total_get_path_length + (double)get_path_length;
-  DEBUG ("total_put_path_length = %f,put_path \n",total_put_path_length);
+  DEBUG ("total_put_path_length = %u,put_path \n",
+         total_put_path_length);
   /* Summarize if profiling is complete */
   if (n_active == n_gets_fail + n_gets_ok)
   {
index c1e7b5f617b276a5f926577e46a6ee56688be897..50a3320fbf9bf6cdca5301683a18228a37fddde3 100644 (file)
@@ -436,7 +436,7 @@ do_dns_read (struct GNUNET_DNSSTUB_RequestSocket *rs,
     {
       GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
                  _("Received DNS response that is too small (%u bytes)"),
-                 r);
+                 (unsigned int) r);
       return GNUNET_NO;
     }
     dns = (struct GNUNET_TUN_DnsHeader *) buf;
index f31e11d8331c7eadb575ca65aaf792c3ed38e8f6..7b9f7d5c90a054ac04f41c8574c535a3d2f1986a 100644 (file)
@@ -1181,7 +1181,7 @@ tcp_from_helper (const struct GNUNET_TUN_TcpHeader *tcp,
     char dbuf[INET6_ADDRSTRLEN];
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                "Received TCP packet with %u bytes going from %s:%u to %s:%u\n",
-               pktlen - sizeof (struct GNUNET_TUN_TcpHeader),
+               (unsigned int) (pktlen - sizeof (struct GNUNET_TUN_TcpHeader)),
                inet_ntop (af,
                           source_ip,
                           sbuf, sizeof (sbuf)),
index e8b632a3fc9ed2d812ccfcf0b426b9b17be70dcd..42677af8a6f7b9b55037a36b33aa0d8badc33340 100644 (file)
@@ -2096,7 +2096,7 @@ create_download_context (struct GNUNET_FS_Handle *h,
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Starting download %p, %u bytes at offset %llu\n",
              dc,
-             (unsigned long long) length,
+             (unsigned int) length,
              (unsigned long long) offset);
   dc->h = h;
   dc->uri = GNUNET_FS_uri_dup (uri);
index 07f4a5653c37501147153fe1f5bf08491c6f5f6d..69876b8b55a8ae4dbf41afadf06e66f8eeefd636 100644 (file)
@@ -204,7 +204,9 @@ write_update_information_graph (struct GNUNET_FS_UpdateInformationGraph *uig)
   if (NULL == wh)
   {
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-                _("Failed to open `%s' for writing: %s\n"), STRERROR (errno));
+                _("Failed to open `%s' for writing: %s\n"),
+                fn,
+                STRERROR (errno));
     GNUNET_free (fn);
     return;
   }
@@ -226,7 +228,9 @@ write_update_information_graph (struct GNUNET_FS_UpdateInformationGraph *uig)
   }
 END:
   if (GNUNET_OK != GNUNET_BIO_write_close (wh))
-    GNUNET_log (GNUNET_ERROR_TYPE_ERROR, _("Failed to write `%s': %s\n"),
+    GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
+                _("Failed to write `%s': %s\n"),
+                fn,
                 STRERROR (errno));
   GNUNET_free (fn);
 }
index 80843006e30309bc5e435a356aaad56c18a3dcfc..530a7ac9b1410994a517cad908e2c53c038ce8ad 100644 (file)
@@ -508,8 +508,9 @@ block_proc (void *cls,
   {
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                 "Indexing block `%s' for offset %llu with index size %u\n",
-                GNUNET_h2s (&chk->query), (unsigned long long) offset,
-                sizeof (struct OnDemandBlock));
+                GNUNET_h2s (&chk->query),
+                (unsigned long long) offset,
+                (unsigned int) sizeof (struct OnDemandBlock));
     odb.offset = GNUNET_htonll (offset);
     odb.file_id = p->data.file.file_id;
     GNUNET_assert (pc->qre == NULL);
index 2706aea3023f56fb6a1af99ba27b8125743467a6..e61442aa3664a100be87b1db1987e6769e341cfc 100644 (file)
@@ -279,7 +279,7 @@ client_response_handler (void *cls,
   }
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Queued reply to query `%s' for local client\n",
-              GNUNET_h2s (&prd->query), (unsigned int) prd->type);
+              GNUNET_h2s (&prd->query));
   if (GNUNET_BLOCK_EVALUATION_OK_LAST != eval)
   {
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
index a76a3827c33e0ea7b11a94b10e02bb447d9d72ce..d7a15fad6c802736359a05323c3d56f478bff200 100644 (file)
@@ -296,7 +296,7 @@ transmit_content (struct MigrationReadyPeer *peer,
   }
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Asking for transmission of %u bytes to %s for migration\n",
-              msize,
+              (unsigned int) msize,
               GNUNET_i2s (GSF_connected_peer_get_identity2_(peer->peer)));
   peer->th = GSF_peer_transmit_ (peer->peer,
                                  GNUNET_NO, 0 /* priority */ ,
index 28480417523d7a61976fc5b2a0f8dc06519c62c2..21471350d195833afa578384e0a1e1f6de1e1122 100644 (file)
@@ -354,12 +354,12 @@ server_start ()
   if ((0 == port) || (port > UINT16_MAX))
   {
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-                _("Invalid port number %llu.  Exiting.\n"),
+                _("Invalid port number %u.  Exiting.\n"),
                 port);
     return GNUNET_SYSERR;
   }
   GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-              _("Businesscard HTTP server starts on %llu\n"),
+              _("Businesscard HTTP server starts on %u\n"),
               port);
   daemon_handle = MHD_start_daemon (MHD_USE_DUAL_STACK | MHD_USE_DEBUG,
                                     (uint16_t) port,
index 5b45af831dd41f9bf661a05e1b2261828e8cc2aa..5c7b8887ec414b6616ea7420c119b8ce40e5afe6 100644 (file)
@@ -479,8 +479,8 @@ adv_transmit_ready (void *cls,
               (unsigned int) transmission_size);
   hostlist_adv_count++;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-              " # Sent advertisement message: %u\n",
-              hostlist_adv_count);
+              " # Sent advertisement message: %llu\n",
+              (unsigned long long) hostlist_adv_count);
   GNUNET_STATISTICS_update (stats,
                             gettext_noop ("# hostlist advertisements send"), 1,
                             GNUNET_NO);
@@ -520,7 +520,7 @@ connect_handler (void *cls,
   }
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Asked CORE to transmit advertisement message with a size of %u bytes to peer `%s'\n",
-              size,
+              (unsigned int) size,
               GNUNET_i2s (peer));
   if (NULL ==
       (th = GNUNET_CORE_notify_transmit_ready (core, GNUNET_YES,
index 855d151cdd013f1b4c79729059d1a49d835ee7e6..1e42af95c90cc3d4d8b02fd2f2d7d7fa0721c5fa 100644 (file)
@@ -692,7 +692,7 @@ GNUNET_error_type_to_string (enum GNUNET_ErrorType kind);
  * a failure of the command 'cmd' with the message given
  * by strerror(errno).
  */
-#define GNUNET_log_strerror_file(level, cmd, filename) do { GNUNET_log(level, _("`%s' failed on file `%s' at %s:%d with error: %s\n"), cmd, filename,__FILE__, __LINE__, STRERROR(errno)); } while(0)
+#define GNUNET_log_strerror_file(level, cmd, filename) do { GNUNET_log(level, _("`%s' failed on file `%s' at %s:%d with error: %s\n"), cmd, filename, __FILE__, __LINE__, STRERROR(errno)); } while(0)
 
 
 /**
index 4611edc6296d7dedd7141075046084f6dc1826a0..6d5b82cc961801ef4533edac797020b29d27500a 100644 (file)
@@ -522,7 +522,7 @@ test_stun (struct GNUNET_NAT_AutoHandle *ah)
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "STUN service listens on port %u\n",
-              port);
+              (unsigned int) port);
   if (GNUNET_NO ==
       GNUNET_NAT_stun_make_request (stun_server, stun_port,
                                    lsock4,
index d4098d1bca55eb8213e4b1802a092e2ca337f52f..4d920465c139d24c6238f399b09f855a5cc27357 100644 (file)
@@ -648,7 +648,7 @@ transmit_ready (void *cls,
     return 0;
   }
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-              "In round s, sending to `%s' estimate with %u bits\n",
+              "In round %s, sending to `%s' estimate with %u bits\n",
               GNUNET_STRINGS_absolute_time_to_string (GNUNET_TIME_absolute_ntoh (size_estimate_messages[idx].timestamp)),
               GNUNET_i2s (&peer_entry->id),
               (unsigned int) ntohl (size_estimate_messages[idx].matching_bits));
@@ -784,7 +784,7 @@ schedule_current_round (void *cls,
   delay =
       get_transmit_delay ((peer_entry->previous_round == GNUNET_NO) ? -1 : 0);
   peer_entry->transmit_task =
-      GNUNET_SCHEDULER_add_delayed (delay, 
+      GNUNET_SCHEDULER_add_delayed (delay,
                                    &transmit_task_cb,
                                    peer_entry);
   return GNUNET_OK;
index 617a0a8e03652973391d5dc86901860156d9b871..5a008ca62847f131e0d29fe6ee029315dc9cc293 100644 (file)
@@ -196,8 +196,9 @@ PEERSTORE_parse_record_message (const struct GNUNET_MessageHeader *message)
   if (req_size < sizeof (struct StoreRecordMessage))
   {
     GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
-                "Received message with invalid size: (%d < %d).\n", req_size,
-                sizeof (struct StoreRecordMessage));
+                "Received message with invalid size: (%d < %d).\n",
+                (int) req_size,
+                (int) sizeof (struct StoreRecordMessage));
     return NULL;
   }
   srm = (struct StoreRecordMessage *) message;
@@ -209,8 +210,11 @@ PEERSTORE_parse_record_message (const struct GNUNET_MessageHeader *message)
   {
     GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
                 "Received message with invalid sizes: (%d + %d + %d + %d != %d).\n",
-                ss_size, key_size, value_size,
-                sizeof (struct StoreRecordMessage), req_size);
+                ss_size,
+                key_size,
+                value_size,
+                (int) sizeof (struct StoreRecordMessage),
+                req_size);
     return NULL;
   }
   record = GNUNET_new (struct GNUNET_PEERSTORE_Record);
index 0f221642811f85059a9eeb460a11bc7d6b5995d1..3edc0295c6694d8c74a2610cd690b8671b6d98b6 100644 (file)
@@ -1790,7 +1790,10 @@ client_recv_slave_join (void *cls, struct GNUNET_SERVER_Client *client,
     {
       GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
                   "%u + %u + %u != %u\n",
-                  sizeof (*req), relay_size, join_msg_size, req_size);
+                  (unsigned int) sizeof (*req),
+                  relay_size,
+                  join_msg_size,
+                  req_size);
       GNUNET_break (0);
       GNUNET_SERVER_client_disconnect (client);
       GNUNET_free (slv);
@@ -2261,7 +2264,9 @@ client_recv_psyc_message (void *cls, struct GNUNET_SERVER_Client *client,
   {
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
                 "%p Message payload too large: %u < %u.\n",
-                chn, GNUNET_MULTICAST_FRAGMENT_MAX_PAYLOAD, size - sizeof (*msg));
+                chn,
+                GNUNET_MULTICAST_FRAGMENT_MAX_PAYLOAD,
+                (unsigned int) (size - sizeof (*msg)));
     GNUNET_break (0);
     transmit_cancel (chn, client);
     GNUNET_SERVER_receive_done (client, GNUNET_SYSERR);
@@ -2298,13 +2303,18 @@ client_recv_psyc_message (void *cls, struct GNUNET_SERVER_Client *client,
  * Received result of GNUNET_PSYCSTORE_membership_store()
  */
 static void
-store_recv_membership_store_result (void *cls, int64_t result,
-                                    const char *err_msg, uint16_t err_msg_size)
+store_recv_membership_store_result (void *cls,
+                                    int64_t result,
+                                    const char *err_msg,
+                                    uint16_t err_msg_size)
 {
   struct Operation *op = cls;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "%p GNUNET_PSYCSTORE_membership_store() returned %" PRId64 " (%.s)\n",
-              op->chn, result, err_msg_size, err_msg);
+              op->chn,
+              result,
+              (int) err_msg_size,
+              err_msg);
 
   if (NULL != op->client)
     client_send_result (op->client, op->op_id, result, err_msg, err_msg_size);
@@ -2432,7 +2442,10 @@ client_recv_history_replay (void *cls, struct GNUNET_SERVER_Client *client,
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
                 "%p History replay #%" PRIu64 ": "
                 "invalid method prefix. size: %u < %u?\n",
-                chn, GNUNET_ntohll (req->op_id), size, sizeof (*req) + 1);
+                chn,
+                GNUNET_ntohll (req->op_id),
+                size,
+                (unsigned int) sizeof (*req) + 1);
     GNUNET_break (0);
     GNUNET_SERVER_receive_done (client, GNUNET_SYSERR);
     return;
index e02f7771497e848b5d5bce11f157493a7dc1a946..801ea628d1cbb9d21c374cf5587f2d9b5656eca6 100644 (file)
@@ -383,7 +383,8 @@ handle_message_get (void *cls,
   {
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
                 "Message get: invalid method prefix. size: %u < %u?\n",
-                size, sizeof (*req) + 1);
+                size,
+                (unsigned int) (sizeof (*req) + 1));
     GNUNET_break (0);
     GNUNET_SERVER_receive_done (client, GNUNET_SYSERR);
     return;
index e16a4e859d03f23328c93c6c36f756f7aa91b120..3dba05b3f672ed1fe47ae48dacd655735cda428a 100644 (file)
@@ -282,7 +282,10 @@ GNUNET_PSYC_log_message (enum GNUNET_ErrorType kind,
   {
     struct GNUNET_PSYC_MessageMethod *meth
       = (struct GNUNET_PSYC_MessageMethod *) msg;
-    GNUNET_log (kind, "\t%.*s\n", size - sizeof (*meth), &meth[1]);
+    GNUNET_log (kind,
+                "\t%.*s\n",
+                (int) (size - sizeof (*meth)),
+                &meth[1]);
     break;
   }
   case GNUNET_MESSAGE_TYPE_PSYC_MESSAGE_MODIFIER:
@@ -291,8 +294,12 @@ GNUNET_PSYC_log_message (enum GNUNET_ErrorType kind,
       = (struct GNUNET_PSYC_MessageModifier *) msg;
     uint16_t name_size = ntohs (mod->name_size);
     char oper = ' ' < mod->oper ? mod->oper : ' ';
-    GNUNET_log (kind, "\t%c%.*s\t%.*s\n", oper, name_size, &mod[1],
-                size - sizeof (*mod) - name_size,
+    GNUNET_log (kind,
+                "\t%c%.*s\t%.*s\n",
+                oper,
+                (int) name_size,
+                &mod[1],
+                (int) (size - sizeof (*mod) - name_size),
                 ((char *) &mod[1]) + name_size);
     break;
   }
index db5432845cfc19cce3233a19afa326f8523bf763..f656818488ecffd12ba7407a6c8fa18f1c31dad9 100644 (file)
@@ -559,7 +559,10 @@ stats_iterator (void *cls,
   {
     GNUNET_log (GNUNET_ERROR_TYPE_INFO,
                 "%p -> %s [%s]: %llu\n",
-                peer, subsystem, name, value);
+                peer,
+                subsystem,
+                name,
+                (unsigned long long) value);
     return GNUNET_OK;
   }
   size =
@@ -569,7 +572,8 @@ stats_iterator (void *cls,
                      peer,
                      subsystem, value, name);
   if (size != GNUNET_DISK_file_write (data_file, output_buffer, size))
-    GNUNET_log (GNUNET_ERROR_TYPE_WARNING, "Unable to write to file!\n");
+    GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
+                "Unable to write to file!\n");
 
   return GNUNET_OK;
 }
index 0ab1aad8f0fd652d7328cab17c7e0732459cdd9d..cd72469576e852b0a76370b3e9d92e1349ec2bf4 100644 (file)
@@ -164,7 +164,7 @@ struct CheckEdgeContext
  * @param len Lenght of token.
  * @param key Hash of next state.
  *
- * @return GNUNET_YES, to keep iterating
+ * @return #GNUNET_YES, to keep iterating
  */
 static int
 check_edge (void *cls,
@@ -175,8 +175,11 @@ check_edge (void *cls,
   struct CheckEdgeContext *ctx = cls;
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-             "edge %.*s [%u]: %s->%s\n",
-              (int) len, token, len, GNUNET_h2s(key));
+             "edge %.*s [%u]: %sn",
+              (int) len,
+              token,
+              (unsigned int) len,
+              GNUNET_h2s (key));
   if (NULL == ctx->xquery)
     return GNUNET_YES;
   if (strlen (ctx->xquery) < len)
@@ -209,7 +212,8 @@ REGEX_BLOCK_check (const struct RegexBlock *block,
   struct CheckEdgeContext ctx;
   int res;
 
-  LOG (GNUNET_ERROR_TYPE_DEBUG, "Block check\n");
+  LOG (GNUNET_ERROR_TYPE_DEBUG,
+       "Block check\n");
   if (GNUNET_OK !=
       REGEX_BLOCK_get_key (block, size,
                           &key))
@@ -229,8 +233,9 @@ REGEX_BLOCK_check (const struct RegexBlock *block,
        ( (NULL == xquery) || ('\0' == xquery[0]) ) )
   {
     LOG (GNUNET_ERROR_TYPE_DEBUG,
-       "  out! Is accepting: %u, xquery %p\n",
-       ntohs(block->is_accepting), xquery);
+         "  out! Is accepting: %u, xquery %p\n",
+         ntohs(block->is_accepting),
+         xquery);
     return GNUNET_OK;
   }
   ctx.xquery = xquery;
index 92d4784429158ace729994a3613907d5df56a618..fa17954b495b0a9c9acebfe81d03dcc786d81cbf 100644 (file)
@@ -409,19 +409,6 @@ kill_httpd ()
 }
 
 
-/**
- * Task run whenever HTTP server is idle for too long. Kill it.
- *
- * @param cls NULL
- */
-static void
-kill_httpd_task (void *cls)
-{
-  httpd_task = NULL;
-  kill_httpd ();
-}
-
-
 /**
  * Schedule MHD.  This function should be called initially when an
  * MHD is first getting its client socket, and will then automatically
index 3162d125244e21b31fd8c73381354d09d19f7d9c..4a1e9cbd0e1db0fea4ec4aa84c83879dc99aadca 100644 (file)
@@ -1179,8 +1179,7 @@ handle_client_disconnect (void *cls,
   if (NULL == client)
     return;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-              "Client disconnected from us.\n",
-              client);
+              "Client disconnected from us.\n");
   s = GNUNET_SERVER_client_get_user_context (client,
                                              struct BobServiceSession);
   if (NULL == s)
index 8d97ea1b658d36f4a593d4a1e4329602fc675456..79a0e961a5a1d4886425a8f2b89af5e4f1a83eb9 100644 (file)
@@ -1470,8 +1470,7 @@ handle_client_disconnect (void *cls,
   if (NULL == client)
     return;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-              "Client disconnected from us.\n",
-              client);
+              "Client disconnected from us.\n");
   s = GNUNET_SERVER_client_get_user_context (client,
                                              struct BobServiceSession);
   if (NULL == s)
index 186a2763e2fec6fae34785d3d44943ab92dfdbf8..6d97f0bb1f091fa90e663998303ea73275a41504 100644 (file)
@@ -192,7 +192,10 @@ set_result_cb (void *cls,
 
   if (element->size != sizeof (struct GNUNET_HashCode))
   {
-    GNUNET_log (GNUNET_ERROR_TYPE_INFO, "wrong element size: %u, expected %u\n", element->size, sizeof (struct GNUNET_HashCode));
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "wrong element size: %u, expected %u\n",
+                element->size,
+                (unsigned int) sizeof (struct GNUNET_HashCode));
     GNUNET_assert (0);
   }
 
index adec5a96d5173fa7fdd916adcbc2af5eeff188cb..8d989dafbeed061a25b51fffee74562499ffd521 100644 (file)
@@ -321,7 +321,7 @@ load (struct GNUNET_SERVER_Handle *server)
   }
   GNUNET_log (GNUNET_ERROR_TYPE_INFO,
               _("Loading %llu bytes of statistics from `%s'\n"),
-              fsize, fn);
+              (unsigned long long) fsize, fn);
   mst = GNUNET_SERVER_mst_create (&inject_message,
                                   server);
   GNUNET_break (GNUNET_OK ==
@@ -475,7 +475,7 @@ transmit (struct GNUNET_SERVER_Client *client,
               e->subsystem->service,
               e->name,
               e->persistent,
-              e->value);
+              (unsigned long long) e->value);
   GNUNET_SERVER_notification_context_unicast (nc, client, &m->header,
                                               GNUNET_NO);
   GNUNET_free (m);
@@ -793,7 +793,7 @@ handle_set (void *cls,
                 "Statistic `%s:%s' updated to value %llu (%d).\n",
                 service,
                 name,
-                pos->value,
+                (unsigned long long) pos->value,
                 pos->persistent);
     if ( (changed) ||
          (1 == initial_set) )
@@ -829,7 +829,7 @@ handle_set (void *cls,
               "New statistic on `%s:%s' with value %llu created.\n",
               service,
               name,
-              pos->value);
+              (unsigned long long) pos->value);
   GNUNET_SERVER_receive_done (client,
                               GNUNET_OK);
 }
@@ -907,7 +907,7 @@ handle_watch (void *cls,
                 "New statistic on `%s:%s' with value %llu created.\n",
                 service,
                 name,
-                pos->value);
+                (unsigned long long) pos->value);
   }
   we = GNUNET_new (struct WatchEntry);
   we->client = client;
index e27e21588d4631f88ac333c21bf811d983781c56..f3c56eb9db7806a904bb636b7c47f62a3f261848 100644 (file)
@@ -513,7 +513,8 @@ read_task (void *cls)
     GNUNET_SCHEDULER_shutdown ();
     return;
   }
-  LOG_DEBUG ("Read %u bytes\n", sread);
+  LOG_DEBUG ("Read %u bytes\n",
+             (unsigned int) sread);
   if (GNUNET_OK !=
       GNUNET_SERVER_mst_receive (tokenizer, NULL, buf, sread, GNUNET_NO,
                                  GNUNET_NO))
index ba20d6d6b4ed2f56d7d79ae0ddfce7e605f1c874..9c12c25a6ba621ad9264ffb38bde6b731f6b66ab 100644 (file)
@@ -429,14 +429,15 @@ GST_handle_peer_create (void *cls, struct GNUNET_SERVER_Client *client,
 
 
 /**
- * Message handler for GNUNET_MESSAGE_TYPE_TESTBED_DESTROYPEER messages
+ * Message handler for #GNUNET_MESSAGE_TYPE_TESTBED_DESTROYPEER messages
  *
  * @param cls NULL
  * @param client identification of the client
  * @param message the actual message
  */
 void
-GST_handle_peer_destroy (void *cls, struct GNUNET_SERVER_Client *client,
+GST_handle_peer_destroy (void *cls,
+                         struct GNUNET_SERVER_Client *client,
                          const struct GNUNET_MessageHeader *message)
 {
   const struct GNUNET_TESTBED_PeerDestroyMessage *msg;
@@ -446,8 +447,9 @@ GST_handle_peer_destroy (void *cls, struct GNUNET_SERVER_Client *client,
 
   msg = (const struct GNUNET_TESTBED_PeerDestroyMessage *) message;
   peer_id = ntohl (msg->peer_id);
-  LOG_DEBUG ("Received peer destory on peer: %u and operation id: %ul\n",
-             peer_id, GNUNET_ntohll (msg->operation_id));
+  LOG_DEBUG ("Received peer destory on peer: %u and operation id: %llu\n",
+             (unsigned int) peer_id,
+             (unsigned long long) GNUNET_ntohll (msg->operation_id));
   if (!VALID_PEER_ID (peer_id))
   {
     LOG (GNUNET_ERROR_TYPE_ERROR,
@@ -494,7 +496,7 @@ GST_handle_peer_destroy (void *cls, struct GNUNET_SERVER_Client *client,
  * Stats a peer
  *
  * @param peer the peer to start
- * @return GNUNET_OK upon success; GNUNET_SYSERR upon failure
+ * @return #GNUNET_OK upon success; #GNUNET_SYSERR upon failure
  */
 static int
 start_peer (struct Peer *peer)
@@ -511,7 +513,7 @@ start_peer (struct Peer *peer)
  * Stops a peer
  *
  * @param peer the peer to stop
- * @return GNUNET_OK upon success; GNUNET_SYSERR upon failure
+ * @return #GNUNET_OK upon success; #GNUNET_SYSERR upon failure
  */
 static int
 stop_peer (struct Peer *peer)
index 119e5e5643422b22bbf4192f0b9272f371a5092b..14eefdfb3f5f932304184056bdff8c4827527595 100644 (file)
@@ -224,7 +224,7 @@ process_payload (const struct GNUNET_HELLO_Address *address,
   {
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                 "Discarded %u bytes type %u payload from peer `%s'\n",
-                msg_size,
+                (unsigned int) msg_size,
                 ntohs (message->type),
                 GNUNET_i2s (&address->peer));
     GNUNET_STATISTICS_update (GST_stats, gettext_noop
@@ -866,9 +866,9 @@ run (void *cls,
   {
     max_fd_rlimit = r_file.rlim_cur;
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-        "Maximum number of open files was: %u/%u\n",
-        r_file.rlim_cur,
-        r_file.rlim_max);
+                "Maximum number of open files was: %u/%u\n",
+                (unsigned int) r_file.rlim_cur,
+                (unsigned int) r_file.rlim_max);
   }
   max_fd_rlimit = (9 * max_fd_rlimit) / 10; /* Keep 10% for rest of transport */
 #endif
index bd3fed6d706e1118514c525adcc1c0942ea9fdb3..7620cdbb1c88969be1fcfd75fd0e2482292bb9de 100644 (file)
@@ -350,7 +350,7 @@ GST_manipulation_send (const struct GNUNET_PeerIdentity *target,
   }
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Delaying %u byte message to peer `%s' with peer specific delay for %s\n",
-              msg_size,
+              (unsigned int) msg_size,
               GNUNET_i2s (target),
               GNUNET_STRINGS_relative_time_to_string (delay,
                                                       GNUNET_YES));
index 65428ef2a0fe24b061b4ce736033946df8ca9714..9d1c9459e7bd8701488b5acbfd8d268e46a2ed73 100644 (file)
@@ -1296,12 +1296,12 @@ transmit_send_continuation (void *cls,
   if (bytes_in_send_queue < mq->message_buf_size)
   {
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
-                "Bytes_in_send_queue `%u', Message_size %u, result: %s, payload %u, on wire %u\n",
+                "Bytes_in_send_queue `%llu', Message_size %u, result: %s, payload %u, on wire %u\n",
                 bytes_in_send_queue,
-                mq->message_buf_size,
+                (unsigned int) mq->message_buf_size,
                 (GNUNET_OK == success) ? "OK" : "FAIL",
-                size_payload,
-                physical);
+                (unsigned int) size_payload,
+                (unsigned int) physical);
     GNUNET_break (0);
   }
 
@@ -1325,7 +1325,7 @@ transmit_send_continuation (void *cls,
              "Sending message to `%s' of type %u with %u bytes was a %s\n",
              GNUNET_i2s (receiver),
               ntohs (((struct GNUNET_MessageHeader *) mq->message_buf)->type),
-              mq->message_buf_size,
+              (unsigned int) mq->message_buf_size,
               (success == GNUNET_OK) ? "success" : "FAILURE");
   if (NULL != mq->cont)
     mq->cont (mq->cont_cls,
@@ -1401,7 +1401,7 @@ try_transmission_to_peer (struct NeighbourMapEntry *n)
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Giving message with %u bytes to plugin session %p\n",
-              mq->message_buf_size,
+              (unsigned int) mq->message_buf_size,
               n->primary_address.session);
   (void) send_with_session (n,
                            mq->message_buf,
@@ -1773,7 +1773,7 @@ GST_neighbours_send (const struct GNUNET_PeerIdentity *target,
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Enqueueing %u bytes to send to peer %s\n",
-              msg_size,
+              (unsigned int) msg_size,
               GNUNET_i2s (target));
   GNUNET_CONTAINER_DLL_insert_tail (n->messages_head,
                                     n->messages_tail,
@@ -2117,7 +2117,7 @@ inbound_bw_tracker_update (void *cls)
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "New inbound delay for peer `%s' is %llu ms\n",
               GNUNET_i2s (&n->id),
-              delay.rel_value_us / 1000);
+              (unsigned long long) delay.rel_value_us / 1000LL);
   papi->update_inbound_delay (papi->cls,
                               &n->id,
                               n->primary_address.session,
@@ -3244,11 +3244,9 @@ GST_neighbours_session_terminated (const struct GNUNET_PeerIdentity *peer,
     /* The session used to send the SYN terminated:
      * this implies a connect error*/
     GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-                "Failed to send SYN in %s with `%s' %p: session terminated\n",
-                "CONNECT_SENT",
+                "Failed to send SYN in CONNECT_SENT with `%s' %p: session terminated\n",
                 GST_plugins_a2s (n->primary_address.address),
-                n->primary_address.session,
-                GNUNET_i2s (peer));
+                n->primary_address.session);
 
     /* Destroy the address since it cannot be used */
     unset_primary_address (n);
@@ -3274,11 +3272,9 @@ GST_neighbours_session_terminated (const struct GNUNET_PeerIdentity *peer,
     break;
   case GNUNET_TRANSPORT_PS_RECONNECT_SENT:
     GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-                "Failed to send SYN in %s with `%s' %p: session terminated\n",
-                "RECONNECT_SENT",
+                "Failed to send SYN in RECONNECT_SENT with `%s' %p: session terminated\n",
                 GST_plugins_a2s (n->primary_address.address),
-                n->primary_address.session,
-                GNUNET_i2s (peer));
+                n->primary_address.session);
     /* Destroy the address since it cannot be used */
     unset_primary_address (n);
     set_state_and_timeout (n,
index 2220790bea9135bd86e6aed89d07c5154f946dde..2b8b426c7f4c209fb67c19f251677f57df45ca2c 100644 (file)
@@ -203,7 +203,7 @@ GNUNET_TRANSPORT_address_to_string (const struct GNUNET_CONFIGURATION_Handle *cf
               client,
               GNUNET_i2s (&address->peer),
               address->transport_name,
-              address->address_length);
+              (unsigned int) address->address_length);
 
   msg = GNUNET_malloc (len);
   msg->header.size = htons (len);
index 6fd871cbeef49ca3bca5f742438c709e0eb20756..faf04cf277417a3bde45847aea8b69841b88883e 100644 (file)
@@ -51,7 +51,7 @@ static char *pwfn;
 
 /**
  * Write our current proof to disk.
- * 
+ *
  * @param cls closure
  */
 static void
@@ -65,7 +65,7 @@ shutdown_task (void *cls)
                             GNUNET_DISK_PERM_USER_WRITE))
     GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING,
                              "write",
-                             proof);
+                             pwfn);
 }
 
 
@@ -129,7 +129,7 @@ find_proof (void *cls)
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Got Proof of Work %llu\n",
-             proof);
+             (unsigned long long) proof);
   proof_task = NULL;
   memcpy (&buf[sizeof (uint64_t)], &pub,
           sizeof (struct GNUNET_CRYPTO_EddsaPublicKey));
@@ -290,7 +290,7 @@ run (void *cls,
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Delay between tries: %s\n",
               GNUNET_STRINGS_relative_time_to_string (proof_find_delay, 1));
-  proof_task = 
+  proof_task =
     GNUNET_SCHEDULER_add_with_priority (GNUNET_SCHEDULER_PRIORITY_IDLE,
                                        &find_proof,
                                        NULL);
index 2c3ac72fa82cc63296dd3c42c4a5498a940c574b..8741aa719b3c5351b5865dc844ef79985cdbc6f5 100644 (file)
@@ -613,7 +613,7 @@ send_to_peer_notify_callback (void *cls, size_t size, void *buf)
   GNUNET_assert (size >= tnq->len);
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Sending %u bytes via cadet channel\n",
-             tnq->len);
+             (unsigned int) tnq->len);
   GNUNET_CONTAINER_DLL_remove (ts->tmq_head,
                               ts->tmq_tail,
                               tnq);
@@ -648,7 +648,7 @@ send_to_channel (struct ChannelMessageQueueEntry *tnq,
 {
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Queueing %u bytes for transmission via cadet channel\n",
-             tnq->len);
+             (unsigned int) tnq->len);
   GNUNET_assert (NULL != ts->channel);
   GNUNET_CONTAINER_DLL_insert_tail (ts->tmq_head,
                                    ts->tmq_tail,