Added configurable DPD

This commit is contained in:
Nikos Mavrogiannopoulos
2013-02-08 21:51:58 +01:00
parent 6ac7986342
commit 5f4b8711ef
8 changed files with 48 additions and 20 deletions
+5 -1
View File
@@ -127,6 +127,7 @@ unsigned j;
READ_NUMERIC("tcp-port", config->port, 1);
READ_NUMERIC("udp-port", config->udp_port, 0);
READ_NUMERIC("keepalive", config->keepalive, 0);
READ_NUMERIC("dpd", config->dpd, 0);
READ_STRING("server-cert", config->cert, 1);
READ_STRING("server-key", config->key, 1);
@@ -201,7 +202,10 @@ static void check_cfg( struct cfg_st *config)
}
if (config->keepalive == 0)
config->keepalive = 30;
config->keepalive = 3600;
if (config->dpd == 0)
config->keepalive = 60;
if (config->udp_port == 0)
config->udp_port = config->port;