aboutsummaryrefslogtreecommitdiff
path: root/src/transport/plugin_transport_udp.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-07-13 15:33:30 +0000
committerChristian Grothoff <christian@grothoff.org>2013-07-13 15:33:30 +0000
commitee21a783ec2bb31b26a508d12ffad5d8b3c866e9 (patch)
tree93b4b89131605a3cde1bdd599c94e0eba37ae6f7 /src/transport/plugin_transport_udp.c
parent9fa742ef8a7b4299f20292107dbe7a40fc08e2bf (diff)
downloadgnunet-ee21a783ec2bb31b26a508d12ffad5d8b3c866e9.tar.gz
gnunet-ee21a783ec2bb31b26a508d12ffad5d8b3c866e9.zip
-add dv_get_network to DV API, improve signature to use 'struct Session *' instead of 'void *'
Diffstat (limited to 'src/transport/plugin_transport_udp.c')
-rw-r--r--src/transport/plugin_transport_udp.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c
index 421da9812..4d74e272e 100644
--- a/src/transport/plugin_transport_udp.c
+++ b/src/transport/plugin_transport_udp.c
@@ -1443,6 +1443,7 @@ session_cmp_it (void *cls,
1443 return GNUNET_YES; 1443 return GNUNET_YES;
1444} 1444}
1445 1445
1446
1446/** 1447/**
1447 * Function obtain the network type for a session 1448 * Function obtain the network type for a session
1448 * 1449 *
@@ -1451,13 +1452,13 @@ session_cmp_it (void *cls,
1451 * @return the network type in HBO or GNUNET_SYSERR 1452 * @return the network type in HBO or GNUNET_SYSERR
1452 */ 1453 */
1453static enum GNUNET_ATS_Network_Type 1454static enum GNUNET_ATS_Network_Type
1454udp_get_network (void *cls, void *session) 1455udp_get_network (void *cls,
1456 struct Session *session)
1455{ 1457{
1456 struct Session *s = (struct Session *) session; 1458 return ntohl (session->ats.value);
1457
1458 return ntohl(s->ats.value);
1459} 1459}
1460 1460
1461
1461/** 1462/**
1462 * Creates a new outbound session the transport service will use to send data to the 1463 * Creates a new outbound session the transport service will use to send data to the
1463 * peer 1464 * peer