aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMartin Schanzenbach <schanzen@gnunet.org>2023-06-01 13:09:08 +0200
committerMartin Schanzenbach <schanzen@gnunet.org>2023-06-01 13:09:08 +0200
commit9f27a1b29d43795c925864e937c61314d144c0a9 (patch)
tree0c5288883bd48aed934ae88ed9c15086c57a7a1e /src
parent811c040a28b4bbc9d1bdba3fd8458c2b1033983d (diff)
downloadgnunet-9f27a1b29d43795c925864e937c61314d144c0a9.tar.gz
gnunet-9f27a1b29d43795c925864e937c61314d144c0a9.zip
ALL: Use <inttypes.h> to properly handle log format strings.
NEWS: -
Diffstat (limited to 'src')
-rw-r--r--src/gnsrecord/json_gnsrecord.c18
-rw-r--r--src/include/platform.h1
-rw-r--r--src/testing/testing.c4
-rw-r--r--src/testing/testing_api_loop.c4
-rw-r--r--src/transport/gnunet-service-tng.c91
-rw-r--r--src/transport/transport_api2_communication.c10
-rw-r--r--src/transport/transport_api_cmd_send_simple_performance.c2
7 files changed, 75 insertions, 55 deletions
diff --git a/src/gnsrecord/json_gnsrecord.c b/src/gnsrecord/json_gnsrecord.c
index 0725cb1a1..cc96e42fb 100644
--- a/src/gnsrecord/json_gnsrecord.c
+++ b/src/gnsrecord/json_gnsrecord.c
@@ -114,9 +114,9 @@ parse_record (json_t *data, struct GNUNET_GNSRECORD_Data *rd)
114 &shadow); 114 &shadow);
115 if (0 != unpack_state) 115 if (0 != unpack_state)
116 { 116 {
117 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 117 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
118 "Error gnsdata object has a wrong format: `%s'!\n", 118 "Error gnsdata object has a wrong format: `%s'!\n",
119 err.text); 119 err.text);
120 unpack_state = json_unpack_ex (data, 120 unpack_state = json_unpack_ex (data,
121 &err, 121 &err,
122 0, 122 0,
@@ -143,7 +143,9 @@ parse_record (json_t *data, struct GNUNET_GNSRECORD_Data *rd)
143 return GNUNET_SYSERR; 143 return GNUNET_SYSERR;
144 } 144 }
145 rd->expiration_time = abs_exp.abs_value_us; 145 rd->expiration_time = abs_exp.abs_value_us;
146 } else { 146 }
147 else
148 {
147 rd->expiration_time = rel_exp.rel_value_us; 149 rd->expiration_time = rel_exp.rel_value_us;
148 } 150 }
149 rd->record_type = GNUNET_GNSRECORD_typename_to_number (record_type); 151 rd->record_type = GNUNET_GNSRECORD_typename_to_number (record_type);
@@ -336,15 +338,17 @@ GNUNET_GNSRECORD_JSON_from_gnsrecord (const char*rname,
336 rd[i].data_size); 338 rd[i].data_size);
337 record_type_str = GNUNET_GNSRECORD_number_to_typename (rd[i].record_type); 339 record_type_str = GNUNET_GNSRECORD_number_to_typename (rd[i].record_type);
338 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 340 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
339 "Packing %s %s %lu %d\n", 341 "Packing %s %s %" PRIu64 " %d\n",
340 value_str, record_type_str, rd[i].expiration_time, rd[i].flags); 342 value_str, record_type_str, rd[i].expiration_time, rd[i].flags);
341 record = json_pack ("{s:s,s:s,s:I,s:b,s:b,s:b,s:b}", 343 record = json_pack ("{s:s,s:s,s:I,s:b,s:b,s:b,s:b}",
342 GNUNET_JSON_GNSRECORD_VALUE, 344 GNUNET_JSON_GNSRECORD_VALUE,
343 value_str, 345 value_str,
344 GNUNET_JSON_GNSRECORD_TYPE, 346 GNUNET_JSON_GNSRECORD_TYPE,
345 record_type_str, 347 record_type_str,
346 (rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION) ? 348 (rd[i].flags
347 GNUNET_JSON_GNSRECORD_RELATIVE_EXPIRATION_TIME : GNUNET_JSON_GNSRECORD_ABSOLUTE_EXPIRATION_TIME, 349 & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION) ?
350 GNUNET_JSON_GNSRECORD_RELATIVE_EXPIRATION_TIME :
351 GNUNET_JSON_GNSRECORD_ABSOLUTE_EXPIRATION_TIME,
348 rd[i].expiration_time, 352 rd[i].expiration_time,
349 GNUNET_JSON_GNSRECORD_FLAG_PRIVATE, 353 GNUNET_JSON_GNSRECORD_FLAG_PRIVATE,
350 rd[i].flags & GNUNET_GNSRECORD_RF_PRIVATE, 354 rd[i].flags & GNUNET_GNSRECORD_RF_PRIVATE,
diff --git a/src/include/platform.h b/src/include/platform.h
index deca323d1..baf6986ed 100644
--- a/src/include/platform.h
+++ b/src/include/platform.h
@@ -44,6 +44,7 @@
44#ifdef HAVE_SYS_TYPES_H 44#ifdef HAVE_SYS_TYPES_H
45#include <sys/types.h> 45#include <sys/types.h>
46#endif 46#endif
47#include <inttypes.h>
47 48
48#ifdef __clang__ 49#ifdef __clang__
49#undef HAVE_STATIC_ASSERT 50#undef HAVE_STATIC_ASSERT
diff --git a/src/testing/testing.c b/src/testing/testing.c
index fe56250a5..e360d7083 100644
--- a/src/testing/testing.c
+++ b/src/testing/testing.c
@@ -1337,7 +1337,7 @@ GNUNET_TESTING_peer_configure (struct GNUNET_TESTING_System *system,
1337 peer->nports = nports; 1337 peer->nports = nports;
1338 return peer; 1338 return peer;
1339 1339
1340 err_ret: 1340err_ret:
1341 GNUNET_free (ss_instances); 1341 GNUNET_free (ss_instances);
1342 GNUNET_free (ports); 1342 GNUNET_free (ports);
1343 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "%s", emsg_); 1343 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "%s", emsg_);
@@ -2848,7 +2848,7 @@ GNUNET_TESTING_get_topo_from_file (const char *filename)
2848 } 2848 }
2849 2849
2850 LOG (GNUNET_ERROR_TYPE_DEBUG, 2850 LOG (GNUNET_ERROR_TYPE_DEBUG,
2851 "file length %lu\n", 2851 "file length %" PRIu64 "\n",
2852 fs); 2852 fs);
2853 data[fs] = '\0'; 2853 data[fs] = '\0';
2854 2854
diff --git a/src/testing/testing_api_loop.c b/src/testing/testing_api_loop.c
index 3ff7d2957..f53e1ecdb 100644
--- a/src/testing/testing_api_loop.c
+++ b/src/testing/testing_api_loop.c
@@ -492,14 +492,14 @@ interpreter_run (void *cls)
492 "Running command `%s'\n", 492 "Running command `%s'\n",
493 cmd->label); 493 cmd->label);
494 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 494 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
495 "start time of %p expected 0 is `%lu'\n", 495 "start time of %p expected 0 is `%" PRIu64 "'\n",
496 cmd, 496 cmd,
497 cmd->start_time.abs_value_us); 497 cmd->start_time.abs_value_us);
498 cmd->start_time 498 cmd->start_time
499 = cmd->last_req_time 499 = cmd->last_req_time
500 = GNUNET_TIME_absolute_get (); 500 = GNUNET_TIME_absolute_get ();
501 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 501 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
502 "start time of %p expected something is `%lu'\n", 502 "start time of %p expected something is `%" PRIu64 "'\n",
503 cmd, 503 cmd,
504 cmd->start_time.abs_value_us); 504 cmd->start_time.abs_value_us);
505 cmd->num_tries = 1; 505 cmd->num_tries = 1;
diff --git a/src/transport/gnunet-service-tng.c b/src/transport/gnunet-service-tng.c
index e797a12a0..23503b998 100644
--- a/src/transport/gnunet-service-tng.c
+++ b/src/transport/gnunet-service-tng.c
@@ -186,20 +186,20 @@
186 * the value chosen here might be too aggressively low! 186 * the value chosen here might be too aggressively low!
187 */ 187 */
188#define DELAY_WARN_THRESHOLD \ 188#define DELAY_WARN_THRESHOLD \
189 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5) 189 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5)
190 190
191/** 191/**
192 * If a DVBox could not be forwarded after this number of 192 * If a DVBox could not be forwarded after this number of
193 * seconds we drop it. 193 * seconds we drop it.
194 */ 194 */
195#define DV_FORWARD_TIMEOUT \ 195#define DV_FORWARD_TIMEOUT \
196 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 60) 196 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 60)
197 197
198/** 198/**
199 * Default value for how long we wait for reliability ack. 199 * Default value for how long we wait for reliability ack.
200 */ 200 */
201#define DEFAULT_ACK_WAIT_DURATION \ 201#define DEFAULT_ACK_WAIT_DURATION \
202 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1) 202 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1)
203 203
204/** 204/**
205 * We only consider queues as "quality" connections when 205 * We only consider queues as "quality" connections when
@@ -207,53 +207,53 @@
207 * the latency of the queue is below this threshold. 207 * the latency of the queue is below this threshold.
208 */ 208 */
209#define DV_QUALITY_RTT_THRESHOLD \ 209#define DV_QUALITY_RTT_THRESHOLD \
210 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1) 210 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1)
211 211
212/** 212/**
213 * How long do we consider a DV path valid if we see no 213 * How long do we consider a DV path valid if we see no
214 * further updates on it? Note: the value chosen here might be too low! 214 * further updates on it? Note: the value chosen here might be too low!
215 */ 215 */
216#define DV_PATH_VALIDITY_TIMEOUT \ 216#define DV_PATH_VALIDITY_TIMEOUT \
217 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5) 217 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5)
218 218
219/** 219/**
220 * How long do we cache backchannel (struct Backtalker) information 220 * How long do we cache backchannel (struct Backtalker) information
221 * after a backchannel goes inactive? 221 * after a backchannel goes inactive?
222 */ 222 */
223#define BACKCHANNEL_INACTIVITY_TIMEOUT \ 223#define BACKCHANNEL_INACTIVITY_TIMEOUT \
224 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5) 224 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5)
225 225
226/** 226/**
227 * How long before paths expire would we like to (re)discover DV paths? Should 227 * How long before paths expire would we like to (re)discover DV paths? Should
228 * be below #DV_PATH_VALIDITY_TIMEOUT. 228 * be below #DV_PATH_VALIDITY_TIMEOUT.
229 */ 229 */
230#define DV_PATH_DISCOVERY_FREQUENCY \ 230#define DV_PATH_DISCOVERY_FREQUENCY \
231 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 4) 231 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 4)
232 232
233/** 233/**
234 * How long are ephemeral keys valid? 234 * How long are ephemeral keys valid?
235 */ 235 */
236#define EPHEMERAL_VALIDITY \ 236#define EPHEMERAL_VALIDITY \
237 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4) 237 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4)
238 238
239/** 239/**
240 * How long do we keep partially reassembled messages around before giving up? 240 * How long do we keep partially reassembled messages around before giving up?
241 */ 241 */
242#define REASSEMBLY_EXPIRATION \ 242#define REASSEMBLY_EXPIRATION \
243 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 4) 243 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 4)
244 244
245/** 245/**
246 * What is the fastest rate at which we send challenges *if* we keep learning 246 * What is the fastest rate at which we send challenges *if* we keep learning
247 * an address (gossip, DHT, etc.)? 247 * an address (gossip, DHT, etc.)?
248 */ 248 */
249#define FAST_VALIDATION_CHALLENGE_FREQ \ 249#define FAST_VALIDATION_CHALLENGE_FREQ \
250 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 1) 250 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 1)
251 251
252/** 252/**
253 * What is the slowest rate at which we send challenges? 253 * What is the slowest rate at which we send challenges?
254 */ 254 */
255#define MAX_VALIDATION_CHALLENGE_FREQ \ 255#define MAX_VALIDATION_CHALLENGE_FREQ \
256 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_DAYS, 1) 256 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_DAYS, 1)
257 257
258/** 258/**
259 * How long until we forget about historic accumulators and thus 259 * How long until we forget about historic accumulators and thus
@@ -261,7 +261,7 @@
261 * active connection experiences without an ACK. 261 * active connection experiences without an ACK.
262 */ 262 */
263#define ACK_CUMMULATOR_TIMEOUT \ 263#define ACK_CUMMULATOR_TIMEOUT \
264 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4) 264 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4)
265 265
266/** 266/**
267 * What is the non-randomized base frequency at which we 267 * What is the non-randomized base frequency at which we
@@ -279,13 +279,13 @@
279 * When do we forget an invalid address for sure? 279 * When do we forget an invalid address for sure?
280 */ 280 */
281#define MAX_ADDRESS_VALID_UNTIL \ 281#define MAX_ADDRESS_VALID_UNTIL \
282 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MONTHS, 1) 282 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MONTHS, 1)
283 283
284/** 284/**
285 * How long do we consider an address valid if we just checked? 285 * How long do we consider an address valid if we just checked?
286 */ 286 */
287#define ADDRESS_VALIDATION_LIFETIME \ 287#define ADDRESS_VALIDATION_LIFETIME \
288 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4) 288 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4)
289 289
290/** 290/**
291 * What is the maximum frequency at which we do address validation? 291 * What is the maximum frequency at which we do address validation?
@@ -3678,7 +3678,8 @@ schedule_transmit_on_queue (struct GNUNET_TIME_Relative delay,
3678 if (0 == queue->q_capacity) 3678 if (0 == queue->q_capacity)
3679 { 3679 {
3680 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 3680 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
3681 "Transmission throttled due to communicator message queue qid %u has capacity %lu.\n", 3681 "Transmission throttled due to communicator message queue qid %u has capacity %"
3682 PRIu64 ".\n",
3682 queue->qid, 3683 queue->qid,
3683 queue->q_capacity); 3684 queue->q_capacity);
3684 GNUNET_STATISTICS_update (GST_stats, 3685 GNUNET_STATISTICS_update (GST_stats,
@@ -4249,7 +4250,7 @@ finish_cmc_handling_with_continue (struct CommunicatorMessageContext *cmc,
4249 struct GNUNET_TRANSPORT_IncomingMessageAck *ack; 4250 struct GNUNET_TRANSPORT_IncomingMessageAck *ack;
4250 4251
4251 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 4252 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
4252 "Acknowledge message with flow control id %lu\n", 4253 "Acknowledge message with flow control id %" PRIu64 "\n",
4253 cmc->im.fc_id); 4254 cmc->im.fc_id);
4254 env = GNUNET_MQ_msg (ack, GNUNET_MESSAGE_TYPE_TRANSPORT_INCOMING_MSG_ACK); 4255 env = GNUNET_MQ_msg (ack, GNUNET_MESSAGE_TYPE_TRANSPORT_INCOMING_MSG_ACK);
4255 ack->reserved = htonl (0); 4256 ack->reserved = htonl (0);
@@ -4465,7 +4466,8 @@ queue_send_msg (struct Queue *queue,
4465 qe = GNUNET_new (struct QueueEntry); 4466 qe = GNUNET_new (struct QueueEntry);
4466 qe->mid = queue->mid_gen; 4467 qe->mid = queue->mid_gen;
4467 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 4468 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
4468 "Create QueueEntry with MID %lu and QID %lu and prefix %s\n", 4469 "Create QueueEntry with MID %" PRIu64
4470 " and QID %u and prefix %s\n",
4469 qe->mid, 4471 qe->mid,
4470 queue->qid, 4472 queue->qid,
4471 queue->tc->details.communicator.address_prefix); 4473 queue->tc->details.communicator.address_prefix);
@@ -4504,7 +4506,7 @@ queue_send_msg (struct Queue *queue,
4504 if (GNUNET_NO == queue->unlimited_length) 4506 if (GNUNET_NO == queue->unlimited_length)
4505 queue->q_capacity--; 4507 queue->q_capacity--;
4506 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 4508 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
4507 "Queue %s with qid %u has capacity %lu\n", 4509 "Queue %s with qid %u has capacity %" PRIu64 "\n",
4508 queue->address, 4510 queue->address,
4509 queue->qid, 4511 queue->qid,
4510 queue->q_capacity); 4512 queue->q_capacity);
@@ -4524,11 +4526,12 @@ queue_send_msg (struct Queue *queue,
4524 } 4526 }
4525 // GNUNET_CONTAINER_multiuuidmap_get (pending_acks, &ack[i].ack_uuid.value); 4527 // GNUNET_CONTAINER_multiuuidmap_get (pending_acks, &ack[i].ack_uuid.value);
4526 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 4528 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
4527 "Sending message MID %lu of type %u (%u) and size %lu with MQ %p QID %lu\n", 4529 "Sending message MID %" PRIu64
4530 " of type %u (%u) and size %lu with MQ %p QID %u\n",
4528 GNUNET_ntohll (smt->mid), 4531 GNUNET_ntohll (smt->mid),
4529 ntohs (((const struct GNUNET_MessageHeader *) payload)->type), 4532 ntohs (((const struct GNUNET_MessageHeader *) payload)->type),
4530 ntohs (smt->header.size), 4533 ntohs (smt->header.size),
4531 payload_size, 4534 (unsigned long) payload_size,
4532 queue->tc->mq, 4535 queue->tc->mq,
4533 queue->qid); 4536 queue->qid);
4534 GNUNET_MQ_send (queue->tc->mq, env); 4537 GNUNET_MQ_send (queue->tc->mq, env);
@@ -5761,7 +5764,6 @@ finish_handling_raw_message (struct VirtualLink *vl,
5761} 5764}
5762 5765
5763 5766
5764
5765/** 5767/**
5766 * Communicator gave us an unencapsulated message to pass as-is to 5768 * Communicator gave us an unencapsulated message to pass as-is to
5767 * CORE. Process the request. 5769 * CORE. Process the request.
@@ -6715,7 +6717,8 @@ path_cleanup_cb (void *cls)
6715} 6717}
6716 6718
6717 6719
6718static void send_msg_from_cache (struct VirtualLink *vl) 6720static void
6721send_msg_from_cache (struct VirtualLink *vl)
6719{ 6722{
6720 6723
6721 const struct GNUNET_PeerIdentity target = vl->target; 6724 const struct GNUNET_PeerIdentity target = vl->target;
@@ -8878,7 +8881,7 @@ handle_validation_response (
8878 (origin_time.abs_value_us > vs->last_challenge_use.abs_value_us)) 8881 (origin_time.abs_value_us > vs->last_challenge_use.abs_value_us))
8879 { 8882 {
8880 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 8883 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
8881 "Diff first use %lu and last use %lu\n", 8884 "Diff first use %" PRIu64 " and last use %" PRIu64 "\n",
8882 vs->first_challenge_use.abs_value_us - origin_time.abs_value_us, 8885 vs->first_challenge_use.abs_value_us - origin_time.abs_value_us,
8883 origin_time.abs_value_us - vs->last_challenge_use.abs_value_us); 8886 origin_time.abs_value_us - vs->last_challenge_use.abs_value_us);
8884 GNUNET_break_op (0); 8887 GNUNET_break_op (0);
@@ -9041,7 +9044,8 @@ handle_incoming_msg (void *cls,
9041 cmc->tc = tc; 9044 cmc->tc = tc;
9042 cmc->im = *im; 9045 cmc->im = *im;
9043 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 9046 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
9044 "Received message with size %u and flow control id %lu via communicator from peer %s\n", 9047 "Received message with size %u and flow control id %" PRIu64
9048 " via communicator from peer %s\n",
9045 ntohs (im->header.size), 9049 ntohs (im->header.size),
9046 im->fc_id, 9050 im->fc_id,
9047 GNUNET_i2s (&im->sender)); 9051 GNUNET_i2s (&im->sender));
@@ -9581,7 +9585,7 @@ update_pm_next_attempt (struct PendingMessage *pm,
9581 { 9585 {
9582 pm->next_attempt = next_attempt; 9586 pm->next_attempt = next_attempt;
9583 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 9587 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
9584 "Next attempt for message <%llu> set to %lu\n", 9588 "Next attempt for message <%" PRIu64 "> set to %" PRIu64 "\n",
9585 pm->logging_uuid, 9589 pm->logging_uuid,
9586 next_attempt.abs_value_us); 9590 next_attempt.abs_value_us);
9587 reorder_root_pm (pm, next_attempt); 9591 reorder_root_pm (pm, next_attempt);
@@ -9593,7 +9597,7 @@ update_pm_next_attempt (struct PendingMessage *pm,
9593 while (NULL != root->frag_parent) 9597 while (NULL != root->frag_parent)
9594 root = root->frag_parent; 9598 root = root->frag_parent;
9595 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 9599 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
9596 "Next attempt for root message <%llu> set to %s\n", 9600 "Next attempt for root message <%" PRIu64 "> set to %s\n",
9597 root->logging_uuid, 9601 root->logging_uuid,
9598 GNUNET_STRINGS_absolute_time_to_string (next_attempt)); 9602 GNUNET_STRINGS_absolute_time_to_string (next_attempt));
9599 root->next_attempt = next_attempt; 9603 root->next_attempt = next_attempt;
@@ -9610,7 +9614,8 @@ update_pm_next_attempt (struct PendingMessage *pm,
9610 { 9614 {
9611 root->next_attempt = next_attempt; 9615 root->next_attempt = next_attempt;
9612 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 9616 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
9613 "Next attempt for fragmented message <%llu> (<%llu>)set to %lu\n", 9617 "Next attempt for fragmented message <%" PRIu64 "> (<%" PRIu64
9618 ">)set to %" PRIu64 "\n",
9614 pm->logging_uuid, 9619 pm->logging_uuid,
9615 root->logging_uuid, 9620 root->logging_uuid,
9616 next_attempt.abs_value_us); 9621 next_attempt.abs_value_us);
@@ -9627,7 +9632,8 @@ update_pm_next_attempt (struct PendingMessage *pm,
9627 if (GNUNET_NO == root->frags_in_flight) 9632 if (GNUNET_NO == root->frags_in_flight)
9628 { 9633 {
9629 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 9634 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
9630 "We have no fragments in flight for message %llu, reorder root! Next attempt is %lu\n", 9635 "We have no fragments in flight for message %" PRIu64
9636 ", reorder root! Next attempt is %" PRIu64 "\n",
9631 root->logging_uuid, 9637 root->logging_uuid,
9632 root->next_attempt.abs_value_us); 9638 root->next_attempt.abs_value_us);
9633 reorder_root_pm (root, root->next_attempt); 9639 reorder_root_pm (root, root->next_attempt);
@@ -9651,7 +9657,8 @@ update_pm_next_attempt (struct PendingMessage *pm,
9651 plus_mean = GNUNET_TIME_relative_add (s1, s2); 9657 plus_mean = GNUNET_TIME_relative_add (s1, s2);
9652 root->next_attempt = GNUNET_TIME_relative_to_absolute (plus_mean); 9658 root->next_attempt = GNUNET_TIME_relative_to_absolute (plus_mean);
9653 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 9659 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
9654 "We have fragments in flight for message %llu, do not reorder root! Actual next attempt %lu\n", 9660 "We have fragments in flight for message %" PRIu64
9661 ", do not reorder root! Actual next attempt %" PRIu64 "\n",
9655 root->logging_uuid, 9662 root->logging_uuid,
9656 root->next_attempt.abs_value_us); 9663 root->next_attempt.abs_value_us);
9657 } 9664 }
@@ -10275,15 +10282,16 @@ handle_send_message_ack (void *cls,
10275 sma->qid)) 10282 sma->qid))
10276 continue; 10283 continue;
10277 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 10284 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
10278 "QueueEntry MID: %llu on queue QID: %lu, Ack MID: %llu Ack QID %LLU\n", 10285 "QueueEntry MID: %" PRIu64 " on queue QID: %u, Ack MID: %"
10279 (unsigned long long) qep->mid, 10286 PRIu64 " Ack QID %u\n",
10280 (unsigned long) queue->qid, 10287 qep->mid,
10288 queue->qid,
10281 GNUNET_ntohll (sma->mid), 10289 GNUNET_ntohll (sma->mid),
10282 ntohl (sma->qid)); 10290 ntohl (sma->qid));
10283 qe = qep; 10291 qe = qep;
10284 if ((NULL != qe->pm) && (qe->pm->qe != qe)) 10292 if ((NULL != qe->pm) && (qe->pm->qe != qe))
10285 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 10293 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
10286 "For pending message %llu we had retransmissions.\n", 10294 "For pending message %" PRIu64 " we had retransmissions.\n",
10287 qe->pm->logging_uuid); 10295 qe->pm->logging_uuid);
10288 break; 10296 break;
10289 } 10297 }
@@ -10291,9 +10299,9 @@ handle_send_message_ack (void *cls,
10291 if (NULL == qe) 10299 if (NULL == qe)
10292 { 10300 {
10293 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 10301 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
10294 "No QueueEntry found for Ack MID %llu QID: %llu\n", 10302 "No QueueEntry found for Ack MID %" PRIu64 " QID: %u\n",
10295 (unsigned long long) GNUNET_ntohll (sma->mid), 10303 GNUNET_ntohll (sma->mid),
10296 (unsigned long) ntohl (sma->qid)); 10304 ntohl (sma->qid));
10297 // TODO I guess this can happen, if the Ack from the peer comes before the Ack from the queue. 10305 // TODO I guess this can happen, if the Ack from the peer comes before the Ack from the queue.
10298 /* this should never happen */ 10306 /* this should never happen */
10299 /*GNUNET_break (0); 10307 /*GNUNET_break (0);
@@ -10349,7 +10357,8 @@ handle_send_message_ack (void *cls,
10349 { 10357 {
10350 // TODO I guess this will never happen, because the communicator triggers this by updating its queue length itself. 10358 // TODO I guess this will never happen, because the communicator triggers this by updating its queue length itself.
10351 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 10359 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
10352 "Transmission rescheduled due to communicator message queue with qid %u has capacity %lu.\n", 10360 "Transmission rescheduled due to communicator message queue with qid %u has capacity %"
10361 PRIu64 ".\n",
10353 qe->queue->qid, 10362 qe->queue->qid,
10354 qe->queue->q_capacity); 10363 qe->queue->q_capacity);
10355 /* message queue has capacity; only resume this one queue */ 10364 /* message queue has capacity; only resume this one queue */
@@ -10810,6 +10819,7 @@ get_address_without_port (const char *address)
10810 return address_without_port; 10819 return address_without_port;
10811} 10820}
10812 10821
10822
10813/** 10823/**
10814 * A new queue has been created, check if any address validation 10824 * A new queue has been created, check if any address validation
10815 * requests have been waiting for it. 10825 * requests have been waiting for it.
@@ -10955,10 +10965,11 @@ handle_add_queue_message (void *cls,
10955 addr_len = ntohs (aqm->header.size) - sizeof(*aqm); 10965 addr_len = ntohs (aqm->header.size) - sizeof(*aqm);
10956 addr = (const char *) &aqm[1]; 10966 addr = (const char *) &aqm[1];
10957 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 10967 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
10958 "New queue %s to %s available with QID %llu and q_len %lu and mtu %u\n", 10968 "New queue %s to %s available with QID %u and q_len %" PRIu64
10969 " and mtu %u\n",
10959 addr, 10970 addr,
10960 GNUNET_i2s (&aqm->receiver), 10971 GNUNET_i2s (&aqm->receiver),
10961 (unsigned long) ntohl (aqm->qid), 10972 ntohl (aqm->qid),
10962 GNUNET_ntohll (aqm->q_len), 10973 GNUNET_ntohll (aqm->q_len),
10963 ntohl (aqm->mtu)); 10974 ntohl (aqm->mtu));
10964 queue = GNUNET_malloc (sizeof(struct Queue) + addr_len); 10975 queue = GNUNET_malloc (sizeof(struct Queue) + addr_len);
@@ -10966,7 +10977,7 @@ handle_add_queue_message (void *cls,
10966 if (GNUNET_TIME_UNIT_ZERO_ABS.abs_value_us != validated_until.abs_value_us) 10977 if (GNUNET_TIME_UNIT_ZERO_ABS.abs_value_us != validated_until.abs_value_us)
10967 { 10978 {
10968 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 10979 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
10969 "New queue with QID %lu inherit validated until\n", 10980 "New queue with QID %u inherit validated until\n",
10970 ntohl (aqm->qid)); 10981 ntohl (aqm->qid));
10971 queue->validated_until = validated_until; 10982 queue->validated_until = validated_until;
10972 } 10983 }
diff --git a/src/transport/transport_api2_communication.c b/src/transport/transport_api2_communication.c
index 3811f463f..35ef039da 100644
--- a/src/transport/transport_api2_communication.c
+++ b/src/transport/transport_api2_communication.c
@@ -546,7 +546,8 @@ handle_incoming_ack (
546 sizeof(struct GNUNET_PeerIdentity)))) 546 sizeof(struct GNUNET_PeerIdentity))))
547 { 547 {
548 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 548 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
549 "Done with message with flow control id %lu for sender %s from sender %s\n", 549 "Done with message with flow control id %" PRIu64
550 " for sender %s from sender %s\n",
550 incoming_ack->fc_id, 551 incoming_ack->fc_id,
551 GNUNET_i2s (&fc->sender), 552 GNUNET_i2s (&fc->sender),
552 GNUNET_i2s (&incoming_ack->sender)); 553 GNUNET_i2s (&incoming_ack->sender));
@@ -557,7 +558,8 @@ handle_incoming_ack (
557 } 558 }
558 } 559 }
559 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 560 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
560 "Message with flow control id %lu from sender %s not found\n", 561 "Message with flow control id %" PRIu64
562 " from sender %s not found\n",
561 incoming_ack->fc_id, 563 incoming_ack->fc_id,
562 GNUNET_i2s (&incoming_ack->sender)); 564 GNUNET_i2s (&incoming_ack->sender));
563 GNUNET_break (0); 565 GNUNET_break (0);
@@ -928,7 +930,7 @@ GNUNET_TRANSPORT_communicator_receive (
928 fc->cb_cls = cb_cls; 930 fc->cb_cls = cb_cls;
929 GNUNET_CONTAINER_DLL_insert (ch->fc_head, ch->fc_tail, fc); 931 GNUNET_CONTAINER_DLL_insert (ch->fc_head, ch->fc_tail, fc);
930 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 932 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
931 "Created flow control id %lu for sender %s\n", 933 "Created flow control id %" PRIu64 " for sender %s\n",
932 fc->id, 934 fc->id,
933 GNUNET_i2s (&fc->sender)); 935 GNUNET_i2s (&fc->sender));
934 } 936 }
@@ -1043,6 +1045,7 @@ GNUNET_TRANSPORT_communicator_address_add (
1043 return ai; 1045 return ai;
1044} 1046}
1045 1047
1048
1046/** 1049/**
1047 * Notify transport service about an address that this communicator no 1050 * Notify transport service about an address that this communicator no
1048 * longer provides for this peer. 1051 * longer provides for this peer.
@@ -1062,6 +1065,7 @@ GNUNET_TRANSPORT_communicator_address_remove (
1062 ai = NULL; 1065 ai = NULL;
1063} 1066}
1064 1067
1068
1065/** 1069/**
1066 * Notify transport service that this communicator no longer provides all its addresses for this peer. 1070 * Notify transport service that this communicator no longer provides all its addresses for this peer.
1067 * 1071 *
diff --git a/src/transport/transport_api_cmd_send_simple_performance.c b/src/transport/transport_api_cmd_send_simple_performance.c
index 5fe8d4de8..7ce3b8bf7 100644
--- a/src/transport/transport_api_cmd_send_simple_performance.c
+++ b/src/transport/transport_api_cmd_send_simple_performance.c
@@ -116,7 +116,7 @@ send_simple_single (void *cls)
116 now = GNUNET_TIME_absolute_get (); 116 now = GNUNET_TIME_absolute_get ();
117 mq_wrapper->num_send++; 117 mq_wrapper->num_send++;
118 LOG (GNUNET_ERROR_TYPE_DEBUG, 118 LOG (GNUNET_ERROR_TYPE_DEBUG,
119 "Sending simple test message with size %u number %lu with mq %p max %u\n", 119 "Sending simple test message with size %u number %u with mq %p max %u\n",
120 mq_wrapper->sss->size, 120 mq_wrapper->sss->size,
121 mq_wrapper->num_send, 121 mq_wrapper->num_send,
122 mq_wrapper->mq, 122 mq_wrapper->mq,