diff options
Diffstat (limited to 'src/core/test_core_api_reliability.c')
-rw-r--r-- | src/core/test_core_api_reliability.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/src/core/test_core_api_reliability.c b/src/core/test_core_api_reliability.c index 6a764c126..b2079ba35 100644 --- a/src/core/test_core_api_reliability.c +++ b/src/core/test_core_api_reliability.c | |||
@@ -156,7 +156,7 @@ terminate_task_error (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
156 | GNUNET_CORE_disconnect (p2.ch); | 156 | GNUNET_CORE_disconnect (p2.ch); |
157 | p2.ch = NULL; | 157 | p2.ch = NULL; |
158 | } | 158 | } |
159 | if (connect_task != GNUNET_SCHEDULER_NO_TASK) | 159 | if (connect_task != GNUNET_SCHEDULER_NO_TASK) |
160 | GNUNET_SCHEDULER_cancel (connect_task); | 160 | GNUNET_SCHEDULER_cancel (connect_task); |
161 | if (p1.th != NULL) | 161 | if (p1.th != NULL) |
162 | { | 162 | { |
@@ -177,8 +177,9 @@ terminate_task_error (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
177 | static void | 177 | static void |
178 | try_connect (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 178 | try_connect (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
179 | { | 179 | { |
180 | connect_task = GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_SECONDS, | 180 | connect_task = |
181 | &try_connect, NULL); | 181 | GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_SECONDS, &try_connect, |
182 | NULL); | ||
182 | GNUNET_TRANSPORT_try_connect (p1.th, &p2.id); | 183 | GNUNET_TRANSPORT_try_connect (p1.th, &p2.id); |
183 | } | 184 | } |
184 | 185 | ||
@@ -239,7 +240,8 @@ transmit_ready (void *cls, size_t size, void *buf) | |||
239 | 240 | ||
240 | static void | 241 | static void |
241 | connect_notify (void *cls, const struct GNUNET_PeerIdentity *peer, | 242 | connect_notify (void *cls, const struct GNUNET_PeerIdentity *peer, |
242 | const struct GNUNET_ATS_Information *atsi, unsigned int atsi_count) | 243 | const struct GNUNET_ATS_Information *atsi, |
244 | unsigned int atsi_count) | ||
243 | { | 245 | { |
244 | struct PeerContext *pc = cls; | 246 | struct PeerContext *pc = cls; |
245 | 247 | ||
@@ -284,7 +286,8 @@ disconnect_notify (void *cls, const struct GNUNET_PeerIdentity *peer) | |||
284 | static int | 286 | static int |
285 | inbound_notify (void *cls, const struct GNUNET_PeerIdentity *other, | 287 | inbound_notify (void *cls, const struct GNUNET_PeerIdentity *other, |
286 | const struct GNUNET_MessageHeader *message, | 288 | const struct GNUNET_MessageHeader *message, |
287 | const struct GNUNET_ATS_Information *atsi, unsigned int atsi_count) | 289 | const struct GNUNET_ATS_Information *atsi, |
290 | unsigned int atsi_count) | ||
288 | { | 291 | { |
289 | #if VERBOSE | 292 | #if VERBOSE |
290 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 293 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -297,7 +300,8 @@ inbound_notify (void *cls, const struct GNUNET_PeerIdentity *other, | |||
297 | static int | 300 | static int |
298 | outbound_notify (void *cls, const struct GNUNET_PeerIdentity *other, | 301 | outbound_notify (void *cls, const struct GNUNET_PeerIdentity *other, |
299 | const struct GNUNET_MessageHeader *message, | 302 | const struct GNUNET_MessageHeader *message, |
300 | const struct GNUNET_ATS_Information *atsi, unsigned int atsi_count) | 303 | const struct GNUNET_ATS_Information *atsi, |
304 | unsigned int atsi_count) | ||
301 | { | 305 | { |
302 | #if VERBOSE | 306 | #if VERBOSE |
303 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 307 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -314,7 +318,8 @@ transmit_ready (void *cls, size_t size, void *buf); | |||
314 | static int | 318 | static int |
315 | process_mtype (void *cls, const struct GNUNET_PeerIdentity *peer, | 319 | process_mtype (void *cls, const struct GNUNET_PeerIdentity *peer, |
316 | const struct GNUNET_MessageHeader *message, | 320 | const struct GNUNET_MessageHeader *message, |
317 | const struct GNUNET_ATS_Information *atsi, unsigned int atsi_count) | 321 | const struct GNUNET_ATS_Information *atsi, |
322 | unsigned int atsi_count) | ||
318 | { | 323 | { |
319 | static int n; | 324 | static int n; |
320 | unsigned int s; | 325 | unsigned int s; |