aboutsummaryrefslogtreecommitdiff
path: root/src/transport/plugin_transport_unix.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2015-10-07 14:15:38 +0000
committerChristian Grothoff <christian@grothoff.org>2015-10-07 14:15:38 +0000
commite5bd8fb4aa72717b8707a4652f14c0735acb52c4 (patch)
tree08398e22b9408cc24b6b9e6cb360fe04b9eeae05 /src/transport/plugin_transport_unix.c
parent572bab1ace57fb9d7acbd218d6940cb1e9a0797b (diff)
downloadgnunet-e5bd8fb4aa72717b8707a4652f14c0735acb52c4.tar.gz
gnunet-e5bd8fb4aa72717b8707a4652f14c0735acb52c4.zip
determine network scope for ATS even if we do not yet have a session and only have an address
Diffstat (limited to 'src/transport/plugin_transport_unix.c')
-rw-r--r--src/transport/plugin_transport_unix.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/transport/plugin_transport_unix.c b/src/transport/plugin_transport_unix.c
index a664941e0..c6ac0e508 100644
--- a/src/transport/plugin_transport_unix.c
+++ b/src/transport/plugin_transport_unix.c
@@ -805,6 +805,22 @@ unix_plugin_get_network (void *cls,
805 805
806 806
807/** 807/**
808 * Function obtain the network type for a session
809 *
810 * @param cls closure (`struct Plugin *`)
811 * @param address the address
812 * @return the network type
813 */
814static enum GNUNET_ATS_Network_Type
815unix_plugin_get_network_for_address (void *cls,
816 const struct GNUNET_HELLO_Address *address)
817
818{
819 return GNUNET_ATS_NET_LOOPBACK;
820}
821
822
823/**
808 * Creates a new outbound session the transport service will use to send data to the 824 * Creates a new outbound session the transport service will use to send data to the
809 * peer 825 * peer
810 * 826 *
@@ -1798,6 +1814,7 @@ libgnunet_plugin_transport_unix_init (void *cls)
1798 api->check_address = &unix_plugin_check_address; 1814 api->check_address = &unix_plugin_check_address;
1799 api->string_to_address = &unix_plugin_string_to_address; 1815 api->string_to_address = &unix_plugin_string_to_address;
1800 api->get_network = &unix_plugin_get_network; 1816 api->get_network = &unix_plugin_get_network;
1817 api->get_network_for_address = &unix_plugin_get_network_for_address;
1801 api->update_session_timeout = &unix_plugin_update_session_timeout; 1818 api->update_session_timeout = &unix_plugin_update_session_timeout;
1802 api->setup_monitor = &unix_plugin_setup_monitor; 1819 api->setup_monitor = &unix_plugin_setup_monitor;
1803 sockets_created = unix_transport_server_start (plugin); 1820 sockets_created = unix_transport_server_start (plugin);