X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=src%2Fstatserv.c;h=ab15c2130478c55822dcada8cc42a8e4a20d4196;hp=4def68a6beaa85b9aa846802cf225fbb46ee0f4e;hb=43a9d38d20c1b1bcd1a03b2445a501d27526bd35;hpb=2af72908b33a7847f9e150902f276f8fc95b74ba diff --git a/src/statserv.c b/src/statserv.c index 4def68a..ab15c21 100644 --- a/src/statserv.c +++ b/src/statserv.c @@ -1,5 +1,5 @@ /* This file is part of the YAZ toolkit. - * Copyright (C) 1995-2010 Index Data + * Copyright (C) 1995-2011 Index Data * See the file LICENSE for details. */ @@ -8,6 +8,10 @@ * \brief Implements GFS logic */ +#if HAVE_CONFIG_H +#include +#endif + #include #include #include @@ -117,7 +121,8 @@ statserv_options_block control_block = { "", /* PID fname */ 0, /* background daemon */ "", /* SSL certificate filename */ - "" /* XML config filename */ + "", /* XML config filename */ + 1 /* keepalive */ }; static int max_sessions = 0; @@ -1259,7 +1264,7 @@ int check_options(int argc, char **argv) get_logbits(1); - while ((ret = options("1a:iszSTl:v:u:c:w:t:k:d:A:p:DC:f:m:r:", + while ((ret = options("1a:iszSTl:v:u:c:w:t:k:Kd:A:p:DC:f:m:r:", argv, argc, &arg)) != -2) { switch (ret) @@ -1337,6 +1342,9 @@ int check_options(int argc, char **argv) } control_block.maxrecordsize = r * 1024; break; + case 'K': + control_block.keepalive = 0; + break; case 'i': control_block.inetd = 1; break;