From ef70fb51271773df97714f739fe7184d4d3a63b8 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 18 Dec 2013 10:08:58 +0000 Subject: [PATCH] -complete API implementation --- src/dv/plugin_transport_dv.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/dv/plugin_transport_dv.c b/src/dv/plugin_transport_dv.c index 8e9ec9d53..db445f1ab 100644 --- a/src/dv/plugin_transport_dv.c +++ b/src/dv/plugin_transport_dv.c @@ -763,6 +763,21 @@ dv_get_network (void *cls, } +/** + * Function that is called to get the keepalive factor. + * GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT is divided by this number to + * calculate the interval between keepalive packets. + * + * @param cls closure with the `struct Plugin` + * @return keepalive factor + */ +static unsigned int +dv_plugin_query_keepalive_factor (void *cls) +{ + return 3; +} + + /** * Entry point for the plugin. * @@ -803,6 +818,7 @@ libgnunet_plugin_transport_dv_init (void *cls) api->check_address = &dv_plugin_check_address; api->address_to_string = &dv_plugin_address_to_string; api->string_to_address = &dv_plugin_string_to_address; + api->query_keepalive_factor = &dv_plugin_query_keepalive_factor; api->get_session = &dv_get_session; api->get_network = &dv_get_network; return api; -- 2.25.1