diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2011-11-04 11:53:34 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2011-11-04 11:53:34 +0000 |
commit | 68f4e2eb8a4502baef703b6d7d2446ed4d47b6da (patch) | |
tree | 69def91c6444a4c603376e54671104c75b85602e /src/transport/gnunet-service-transport_neighbours.c | |
parent | b2a408ab20ced9531db3d09b53eb1de0df03be9b (diff) | |
download | gnunet-68f4e2eb8a4502baef703b6d7d2446ed4d47b6da.tar.gz gnunet-68f4e2eb8a4502baef703b6d7d2446ed4d47b6da.zip |
Diffstat (limited to 'src/transport/gnunet-service-transport_neighbours.c')
-rw-r--r-- | src/transport/gnunet-service-transport_neighbours.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/src/transport/gnunet-service-transport_neighbours.c b/src/transport/gnunet-service-transport_neighbours.c index cfe988ac4..155efbb2f 100644 --- a/src/transport/gnunet-service-transport_neighbours.c +++ b/src/transport/gnunet-service-transport_neighbours.c | |||
@@ -580,14 +580,20 @@ send_with_plugin ( const struct GNUNET_PeerIdentity * target, | |||
580 | size_t ret = GNUNET_SYSERR; | 580 | size_t ret = GNUNET_SYSERR; |
581 | 581 | ||
582 | /* FIXME : ats returns an address with all values 0 */ | 582 | /* FIXME : ats returns an address with all values 0 */ |
583 | if (((plugin_name == NULL) && (addr == NULL) && (addrlen == 0 )) || | 583 | if (plugin_name == NULL) |
584 | ((plugin_name == NULL) && (session == NULL)) || | ||
585 | ((plugin_name == NULL) && (addr == NULL) && (addrlen == 0 ) && (force_address == GNUNET_YES))) | ||
586 | { | 584 | { |
587 | if (cont != NULL) | 585 | if (cont != NULL) |
588 | cont (cont_cls, target, GNUNET_SYSERR); | 586 | cont (cont_cls, target, GNUNET_SYSERR); |
589 | return GNUNET_SYSERR; | 587 | return GNUNET_SYSERR; |
590 | } | 588 | } |
589 | |||
590 | if ((session == NULL) && (addr == NULL) && (addrlen == 0)) | ||
591 | { | ||
592 | if (cont != NULL) | ||
593 | cont (cont_cls, target, GNUNET_SYSERR); | ||
594 | return GNUNET_SYSERR; | ||
595 | } | ||
596 | |||
591 | papi = GST_plugins_find (plugin_name); | 597 | papi = GST_plugins_find (plugin_name); |
592 | if (papi == NULL) | 598 | if (papi == NULL) |
593 | { | 599 | { |
@@ -1001,7 +1007,6 @@ ats_suggest_cancel (void *cls, | |||
1001 | disconnect_neighbour(n); | 1007 | disconnect_neighbour(n); |
1002 | } | 1008 | } |
1003 | 1009 | ||
1004 | |||
1005 | /** | 1010 | /** |
1006 | * Cleanup the neighbours subsystem. | 1011 | * Cleanup the neighbours subsystem. |
1007 | */ | 1012 | */ |
@@ -1217,10 +1222,10 @@ GST_neighbours_switch_to_address_3way (const struct GNUNET_PeerIdentity *peer, | |||
1217 | GNUNET_break_op(0); | 1222 | GNUNET_break_op(0); |
1218 | checks_failed = GNUNET_YES; | 1223 | checks_failed = GNUNET_YES; |
1219 | } | 1224 | } |
1220 | if ((address == NULL) && (address_len == 0 )) | 1225 | if ((address == NULL) && (address_len == 0 ) && (session == NULL)) |
1221 | { | 1226 | { |
1222 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 1227 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
1223 | "ATS offered suggested us empty address: address NULL"); | 1228 | "ATS offered suggested us empty address: address NULL & session NULL"); |
1224 | GNUNET_break_op(0); | 1229 | GNUNET_break_op(0); |
1225 | checks_failed = GNUNET_YES; | 1230 | checks_failed = GNUNET_YES; |
1226 | } | 1231 | } |