diff options
Diffstat (limited to 'src/util/socks.c')
-rw-r--r-- | src/util/socks.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/util/socks.c b/src/util/socks.c index bda8765ad..1525b3c75 100644 --- a/src/util/socks.c +++ b/src/util/socks.c | |||
@@ -296,7 +296,7 @@ reciever (void *cls, | |||
296 | { | 296 | { |
297 | struct GNUNET_SOCKS_Handshake * ih = cls; | 297 | struct GNUNET_SOCKS_Handshake * ih = cls; |
298 | GNUNET_assert (&ih->inend[available] < &ih->inbuf[1024]); | 298 | GNUNET_assert (&ih->inend[available] < &ih->inbuf[1024]); |
299 | memcpy(ih->inend, buf, available); | 299 | GNUNET_memcpy(ih->inend, buf, available); |
300 | ih->inend += available; | 300 | ih->inend += available; |
301 | SOCKS5_handshake_step (ih); | 301 | SOCKS5_handshake_step (ih); |
302 | } | 302 | } |
@@ -375,7 +375,7 @@ transmit_ready (void *cls, | |||
375 | GNUNET_assert (e <= &ih->outbuf[1024]); | 375 | GNUNET_assert (e <= &ih->outbuf[1024]); |
376 | unsigned l = e - b; | 376 | unsigned l = e - b; |
377 | GNUNET_assert (size >= l && l >= 0); | 377 | GNUNET_assert (size >= l && l >= 0); |
378 | memcpy(buf, b, l); | 378 | GNUNET_memcpy(buf, b, l); |
379 | register_reciever (ih, register_reciever_wants(ih)); | 379 | register_reciever (ih, register_reciever_wants(ih)); |
380 | return l; | 380 | return l; |
381 | } | 381 | } |
@@ -497,11 +497,11 @@ GNUNET_SOCKS_set_handshake_destination (struct GNUNET_SOCKS_Handshake *ih, | |||
497 | /* Specify destination */ | 497 | /* Specify destination */ |
498 | if (1 == inet_pton(AF_INET,host,&ia.in4)) { | 498 | if (1 == inet_pton(AF_INET,host,&ia.in4)) { |
499 | *(b++)= 1; /* IPv4 */ | 499 | *(b++)= 1; /* IPv4 */ |
500 | memcpy (b, &ia.in4, sizeof(struct in_addr)); | 500 | GNUNET_memcpy (b, &ia.in4, sizeof(struct in_addr)); |
501 | b += sizeof(struct in_addr); /* 4 */ | 501 | b += sizeof(struct in_addr); /* 4 */ |
502 | } else if (1 == inet_pton(AF_INET6,host,&ia.in6)) { | 502 | } else if (1 == inet_pton(AF_INET6,host,&ia.in6)) { |
503 | *(b++)= 4; /* IPv6 */ | 503 | *(b++)= 4; /* IPv6 */ |
504 | memcpy (b, &ia.in6, sizeof(struct in6_addr)); | 504 | GNUNET_memcpy (b, &ia.in6, sizeof(struct in6_addr)); |
505 | b += sizeof(struct in6_addr); /* 16 */ | 505 | b += sizeof(struct in6_addr); /* 16 */ |
506 | } else { | 506 | } else { |
507 | *(b++)= 3; /* hostname */ | 507 | *(b++)= 3; /* hostname */ |