diff options
author | Christian Grothoff <christian@grothoff.org> | 2015-02-03 14:27:56 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2015-02-03 14:27:56 +0000 |
commit | 7aff55d7ef03ec7172e5d219e5a22100c21e8425 (patch) | |
tree | 2958999e380146ab541263005b4d0191ff991fd0 /src/transport/gnunet-service-transport.c | |
parent | b2e99dd91c01b5fcc16b3b1031df897aeec05eef (diff) | |
download | gnunet-7aff55d7ef03ec7172e5d219e5a22100c21e8425.tar.gz gnunet-7aff55d7ef03ec7172e5d219e5a22100c21e8425.zip |
separate ATS interface scanning logic from ATS scheduling logic
Diffstat (limited to 'src/transport/gnunet-service-transport.c')
-rw-r--r-- | src/transport/gnunet-service-transport.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/transport/gnunet-service-transport.c b/src/transport/gnunet-service-transport.c index e65af664c..633a707b4 100644 --- a/src/transport/gnunet-service-transport.c +++ b/src/transport/gnunet-service-transport.c | |||
@@ -147,6 +147,11 @@ static struct SessionKiller *sk_head; | |||
147 | static struct SessionKiller *sk_tail; | 147 | static struct SessionKiller *sk_tail; |
148 | 148 | ||
149 | /** | 149 | /** |
150 | * Interface scanner determines our LAN address range(s). | ||
151 | */ | ||
152 | static struct GNUNET_ATS_InterfaceScanner *is; | ||
153 | |||
154 | /** | ||
150 | * FIXME | 155 | * FIXME |
151 | */ | 156 | */ |
152 | struct BlacklistCheckContext *bc_head; | 157 | struct BlacklistCheckContext *bc_head; |
@@ -659,9 +664,9 @@ plugin_env_address_to_type (void *cls, | |||
659 | GNUNET_break(0); | 664 | GNUNET_break(0); |
660 | return GNUNET_ATS_NET_UNSPECIFIED; | 665 | return GNUNET_ATS_NET_UNSPECIFIED; |
661 | } | 666 | } |
662 | return GNUNET_ATS_address_get_type (GST_ats, | 667 | return GNUNET_ATS_scanner_address_get_type (is, |
663 | addr, | 668 | addr, |
664 | addrlen); | 669 | addrlen); |
665 | } | 670 | } |
666 | 671 | ||
667 | 672 | ||
@@ -864,6 +869,8 @@ shutdown_task (void *cls, | |||
864 | GST_ats = NULL; | 869 | GST_ats = NULL; |
865 | GNUNET_ATS_connectivity_done (GST_ats_connect); | 870 | GNUNET_ATS_connectivity_done (GST_ats_connect); |
866 | GST_ats_connect = NULL; | 871 | GST_ats_connect = NULL; |
872 | GNUNET_ATS_scanner_done (is); | ||
873 | is = NULL; | ||
867 | GST_clients_stop (); | 874 | GST_clients_stop (); |
868 | GST_blacklist_stop (); | 875 | GST_blacklist_stop (); |
869 | GST_hello_stop (); | 876 | GST_hello_stop (); |
@@ -993,6 +1000,7 @@ run (void *cls, | |||
993 | GST_hello_start (friend_only, &process_hello_update, NULL ); | 1000 | GST_hello_start (friend_only, &process_hello_update, NULL ); |
994 | GNUNET_assert(NULL != GST_hello_get()); | 1001 | GNUNET_assert(NULL != GST_hello_get()); |
995 | GST_blacklist_start (GST_server, GST_cfg, &GST_my_identity); | 1002 | GST_blacklist_start (GST_server, GST_cfg, &GST_my_identity); |
1003 | is = GNUNET_ATS_scanner_init (); | ||
996 | GST_ats_connect = GNUNET_ATS_connectivity_init (GST_cfg); | 1004 | GST_ats_connect = GNUNET_ATS_connectivity_init (GST_cfg); |
997 | GST_ats = GNUNET_ATS_scheduling_init (GST_cfg, | 1005 | GST_ats = GNUNET_ATS_scheduling_init (GST_cfg, |
998 | &ats_request_address_change, | 1006 | &ats_request_address_change, |