diff options
Diffstat (limited to 'src/transport/transport_api2_communication.c')
-rw-r--r-- | src/transport/transport_api2_communication.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/transport/transport_api2_communication.c b/src/transport/transport_api2_communication.c index 446add6f6..2a80db87b 100644 --- a/src/transport/transport_api2_communication.c +++ b/src/transport/transport_api2_communication.c | |||
@@ -904,6 +904,10 @@ GNUNET_TRANSPORT_communicator_receive ( | |||
904 | struct GNUNET_TRANSPORT_IncomingMessage *im; | 904 | struct GNUNET_TRANSPORT_IncomingMessage *im; |
905 | uint16_t msize; | 905 | uint16_t msize; |
906 | 906 | ||
907 | |||
908 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
909 | "communicator receive\n"); | ||
910 | |||
907 | if (NULL == ch->mq) | 911 | if (NULL == ch->mq) |
908 | return GNUNET_SYSERR; | 912 | return GNUNET_SYSERR; |
909 | if ((NULL == cb) && (GNUNET_MQ_get_length (ch->mq) >= ch->max_queue_length)) | 913 | if ((NULL == cb) && (GNUNET_MQ_get_length (ch->mq) >= ch->max_queue_length)) |
@@ -986,6 +990,9 @@ GNUNET_TRANSPORT_communicator_mq_add ( | |||
986 | { | 990 | { |
987 | struct GNUNET_TRANSPORT_QueueHandle *qh; | 991 | struct GNUNET_TRANSPORT_QueueHandle *qh; |
988 | 992 | ||
993 | // Do not notify the service if there is no intial capacity. | ||
994 | GNUNET_assert (0 < q_len); | ||
995 | |||
989 | qh = GNUNET_new (struct GNUNET_TRANSPORT_QueueHandle); | 996 | qh = GNUNET_new (struct GNUNET_TRANSPORT_QueueHandle); |
990 | qh->ch = ch; | 997 | qh->ch = ch; |
991 | qh->peer = *peer; | 998 | qh->peer = *peer; |
@@ -1106,7 +1113,7 @@ GNUNET_TRANSPORT_communicator_address_remove ( | |||
1106 | */ | 1113 | */ |
1107 | void | 1114 | void |
1108 | GNUNET_TRANSPORT_communicator_address_remove_all ( | 1115 | GNUNET_TRANSPORT_communicator_address_remove_all ( |
1109 | struct GNUNET_TRANSPORT_CommunicatorHandle *ch) | 1116 | struct GNUNET_TRANSPORT_CommunicatorHandle *ch) |
1110 | { | 1117 | { |
1111 | for (struct GNUNET_TRANSPORT_AddressIdentifier *ai = ch->ai_head; NULL != ai; | 1118 | for (struct GNUNET_TRANSPORT_AddressIdentifier *ai = ch->ai_head; NULL != ai; |
1112 | ai = ai->next) | 1119 | ai = ai->next) |