summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2019-06-25 15:31:14 +0200
committerChristian Grothoff <christian@grothoff.org>2019-06-25 15:31:20 +0200
commit34fbc7c7e49e6234d4b984ca7fe79f43ce86f3e3 (patch)
treef5ac1010c710baa12fe4b191952a79c7c0f650a5
parent198e0e3663fedaa753d59e6e700c5ddb5ef64d20 (diff)
indent
-rw-r--r--src/transport/gnunet-communicator-udp.c24
1 files changed, 13 insertions, 11 deletions
diff --git a/src/transport/gnunet-communicator-udp.c b/src/transport/gnunet-communicator-udp.c
index 6193b9225..68635b5bf 100644
--- a/src/transport/gnunet-communicator-udp.c
+++ b/src/transport/gnunet-communicator-udp.c
@@ -2094,13 +2094,14 @@ setup_receiver_mq (struct ReceiverAddress *receiver)
}
/* => Effective MTU for CORE will range from 1080 (IPv6 + KX) to
1404 (IPv4 + Box) bytes, depending on circumstances... */
- receiver->mq = GNUNET_MQ_queue_for_callbacks (&mq_send,
- &mq_destroy,
- &mq_cancel,
- receiver,
- NULL,
- &mq_error,
- receiver);
+ if (NULL == receiver->mq)
+ receiver->mq = GNUNET_MQ_queue_for_callbacks (&mq_send,
+ &mq_destroy,
+ &mq_cancel,
+ receiver,
+ NULL,
+ &mq_error,
+ receiver);
receiver->qh =
GNUNET_TRANSPORT_communicator_mq_add (ch,
&receiver->target,
@@ -2153,10 +2154,11 @@ mq_init (void *cls, const struct GNUNET_PeerIdentity *peer, const char *address)
receiver->address_len = in_len;
receiver->target = *peer;
receiver->nt = GNUNET_NT_scanner_get_type (is, in, in_len);
- (void) GNUNET_CONTAINER_multipeermap_put (receivers,
- &receiver->target,
- receiver,
- GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE);
+ (void) GNUNET_CONTAINER_multipeermap_put (
+ receivers,
+ &receiver->target,
+ receiver,
+ GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE);
receiver->timeout =
GNUNET_TIME_relative_to_absolute (GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT);
receiver->hn = GNUNET_CONTAINER_heap_insert (receivers_heap,