diff options
Diffstat (limited to 'src/transport/test_transport_plugin_cmd_simple_send_dv.c')
-rw-r--r-- | src/transport/test_transport_plugin_cmd_simple_send_dv.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/src/transport/test_transport_plugin_cmd_simple_send_dv.c b/src/transport/test_transport_plugin_cmd_simple_send_dv.c index ac3e8b24b..c07fd3cf4 100644 --- a/src/transport/test_transport_plugin_cmd_simple_send_dv.c +++ b/src/transport/test_transport_plugin_cmd_simple_send_dv.c | |||
@@ -113,7 +113,7 @@ handle_test (void *cls, | |||
113 | GNUNET_TESTING_get_trait_async_context (&block_receive, | 113 | GNUNET_TESTING_get_trait_async_context (&block_receive, |
114 | &ac_block); | 114 | &ac_block); |
115 | 115 | ||
116 | if ( connected == number_received) | 116 | if (connected == number_received) |
117 | { | 117 | { |
118 | if (NULL != ac_block->is) | 118 | if (NULL != ac_block->is) |
119 | { | 119 | { |
@@ -142,7 +142,7 @@ handle_test (void *cls, | |||
142 | struct GNUNET_TESTING_BarrierList * | 142 | struct GNUNET_TESTING_BarrierList * |
143 | get_waiting_for_barriers () | 143 | get_waiting_for_barriers () |
144 | { | 144 | { |
145 | //No Barrier | 145 | // No Barrier |
146 | return GNUNET_new (struct GNUNET_TESTING_BarrierList); | 146 | return GNUNET_new (struct GNUNET_TESTING_BarrierList); |
147 | } | 147 | } |
148 | 148 | ||
@@ -201,19 +201,21 @@ notify_connect (struct GNUNET_TESTING_Interpreter *is, | |||
201 | { | 201 | { |
202 | const struct ConnectPeersState *cps; | 202 | const struct ConnectPeersState *cps; |
203 | const struct GNUNET_TESTING_Command *cmd; | 203 | const struct GNUNET_TESTING_Command *cmd; |
204 | void *ret = NULL; | ||
205 | 204 | ||
206 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 205 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
207 | "notify_connect peer %s\n", | 206 | "notify_connect peer %s\n", |
208 | GNUNET_i2s (peer)); | 207 | GNUNET_i2s (peer)); |
208 | // FIXME: modifying future is a bit unclean, not easy to follow logic; | ||
209 | // might be better to when reaching the future command to look into | ||
210 | // the past... | ||
209 | cmd = GNUNET_TESTING_interpreter_lookup_command_all (is, | 211 | cmd = GNUNET_TESTING_interpreter_lookup_command_all (is, |
210 | "connect-peers"); | 212 | "connect-peers"); |
213 | // FIXME: check return value! | ||
211 | GNUNET_TRANSPORT_get_trait_connect_peer_state (cmd, | 214 | GNUNET_TRANSPORT_get_trait_connect_peer_state (cmd, |
212 | &cps); | 215 | &cps); |
213 | cps->notify_connect (is, | 216 | cps->notify_connect (is, |
214 | peer); | 217 | peer); |
215 | 218 | return NULL; | |
216 | return ret; | ||
217 | } | 219 | } |
218 | 220 | ||
219 | 221 | ||
@@ -382,9 +384,9 @@ start_testcase (GNUNET_TESTING_cmd_helper_write_cb write_message, | |||
382 | ts->write_message = write_message; | 384 | ts->write_message = write_message; |
383 | 385 | ||
384 | is = GNUNET_TESTING_run (commands, | 386 | is = GNUNET_TESTING_run (commands, |
385 | TIMEOUT, | 387 | TIMEOUT, |
386 | &handle_result, | 388 | &handle_result, |
387 | ts); | 389 | ts); |
388 | return is; | 390 | return is; |
389 | } | 391 | } |
390 | 392 | ||