diff options
author | Bart Polot <bart@net.in.tum.de> | 2014-12-15 07:17:21 +0000 |
---|---|---|
committer | Bart Polot <bart@net.in.tum.de> | 2014-12-15 07:17:21 +0000 |
commit | c54ef7bb2266765e3596b8057069a4229a3da99e (patch) | |
tree | 843dcdfa2a23c525fd9f248f87075771cb2533a3 /src/cadet | |
parent | bd94aa6fe80a7687c3727ebcdb3ba5185d3b8b11 (diff) | |
download | gnunet-c54ef7bb2266765e3596b8057069a4229a3da99e.tar.gz gnunet-c54ef7bb2266765e3596b8057069a4229a3da99e.zip |
- avoid usage of direct stdio sprintf
Diffstat (limited to 'src/cadet')
-rw-r--r-- | src/cadet/gnunet-service-cadet_channel.c | 2 | ||||
-rw-r--r-- | src/cadet/gnunet-service-cadet_connection.c | 2 | ||||
-rw-r--r-- | src/cadet/gnunet-service-cadet_local.c | 2 | ||||
-rw-r--r-- | src/cadet/gnunet-service-cadet_tunnel.c | 4 |
4 files changed, 5 insertions, 5 deletions
diff --git a/src/cadet/gnunet-service-cadet_channel.c b/src/cadet/gnunet-service-cadet_channel.c index 74186310a..7f92e8b5e 100644 --- a/src/cadet/gnunet-service-cadet_channel.c +++ b/src/cadet/gnunet-service-cadet_channel.c | |||
@@ -2439,7 +2439,7 @@ GCCH_2s (const struct CadetChannel *ch) | |||
2439 | if (NULL == ch) | 2439 | if (NULL == ch) |
2440 | return "(NULL Channel)"; | 2440 | return "(NULL Channel)"; |
2441 | 2441 | ||
2442 | sprintf (buf, "%s:%u gid:%X (%X / %X)", | 2442 | SPRINTF (buf, "%s:%u gid:%X (%X / %X)", |
2443 | GCT_2s (ch->t), ch->port, ch->gid, ch->lid_root, ch->lid_dest); | 2443 | GCT_2s (ch->t), ch->port, ch->gid, ch->lid_root, ch->lid_dest); |
2444 | 2444 | ||
2445 | return buf; | 2445 | return buf; |
diff --git a/src/cadet/gnunet-service-cadet_connection.c b/src/cadet/gnunet-service-cadet_connection.c index 2cf6d2dd9..b35b7ebac 100644 --- a/src/cadet/gnunet-service-cadet_connection.c +++ b/src/cadet/gnunet-service-cadet_connection.c | |||
@@ -3212,7 +3212,7 @@ GCC_2s (const struct CadetConnection *c) | |||
3212 | { | 3212 | { |
3213 | static char buf[128]; | 3213 | static char buf[128]; |
3214 | 3214 | ||
3215 | sprintf (buf, "%s (->%s)", | 3215 | SPRINTF (buf, "%s (->%s)", |
3216 | GNUNET_h2s (GC_h2hc (GCC_get_id (c))), GCT_2s (c->t)); | 3216 | GNUNET_h2s (GC_h2hc (GCC_get_id (c))), GCT_2s (c->t)); |
3217 | return buf; | 3217 | return buf; |
3218 | } | 3218 | } |
diff --git a/src/cadet/gnunet-service-cadet_local.c b/src/cadet/gnunet-service-cadet_local.c index 10e1a0ab4..caa61db28 100644 --- a/src/cadet/gnunet-service-cadet_local.c +++ b/src/cadet/gnunet-service-cadet_local.c | |||
@@ -1375,6 +1375,6 @@ GML_2s (const struct CadetClient *c) | |||
1375 | { | 1375 | { |
1376 | static char buf[32]; | 1376 | static char buf[32]; |
1377 | 1377 | ||
1378 | sprintf (buf, "%u", c->id); | 1378 | SPRINTF (buf, "%u", c->id); |
1379 | return buf; | 1379 | return buf; |
1380 | } | 1380 | } |
diff --git a/src/cadet/gnunet-service-cadet_tunnel.c b/src/cadet/gnunet-service-cadet_tunnel.c index 0b314f9a2..93c111994 100644 --- a/src/cadet/gnunet-service-cadet_tunnel.c +++ b/src/cadet/gnunet-service-cadet_tunnel.c | |||
@@ -354,7 +354,7 @@ cstate2s (enum CadetTunnelCState cs) | |||
354 | case CADET_TUNNEL_SHUTDOWN: | 354 | case CADET_TUNNEL_SHUTDOWN: |
355 | return "CADET_TUNNEL_SHUTDOWN"; | 355 | return "CADET_TUNNEL_SHUTDOWN"; |
356 | default: | 356 | default: |
357 | sprintf (buf, "%u (UNKNOWN STATE)", cs); | 357 | SPRINTF (buf, "%u (UNKNOWN STATE)", cs); |
358 | return buf; | 358 | return buf; |
359 | } | 359 | } |
360 | return ""; | 360 | return ""; |
@@ -386,7 +386,7 @@ estate2s (enum CadetTunnelEState es) | |||
386 | case CADET_TUNNEL_KEY_REKEY: | 386 | case CADET_TUNNEL_KEY_REKEY: |
387 | return "CADET_TUNNEL_KEY_REKEY"; | 387 | return "CADET_TUNNEL_KEY_REKEY"; |
388 | default: | 388 | default: |
389 | sprintf (buf, "%u (UNKNOWN STATE)", es); | 389 | SPRINTF (buf, "%u (UNKNOWN STATE)", es); |
390 | return buf; | 390 | return buf; |
391 | } | 391 | } |
392 | return ""; | 392 | return ""; |