* See the file LICENSE for details.
* Sebastian Hammer, Adam Dickmeiss
*
* NT threaded server code by
* Chas Woodfield, Fretwell Downing Informatics.
*
* See the file LICENSE for details.
* Sebastian Hammer, Adam Dickmeiss
*
* NT threaded server code by
* Chas Woodfield, Fretwell Downing Informatics.
*
"", /* diagnostic output to stderr */
"tcp:@:9999", /* default listener port */
PROTO_Z3950, /* default application protocol */
"", /* diagnostic output to stderr */
"tcp:@:9999", /* default listener port */
PROTO_Z3950, /* default application protocol */
1024*1024, /* maximum PDU size (approx.) to allow */
"default-config", /* configuration name to pass to backend */
"", /* set user id */
1024*1024, /* maximum PDU size (approx.) to allow */
"default-config", /* configuration name to pass to backend */
"", /* set user id */
0, /* default value for inet deamon */
0, /* handle (for service, etc) */
0, /* bend_init handle */
0, /* default value for inet deamon */
0, /* handle (for service, etc) */
0, /* bend_init handle */
"Server", /* NT application Name */
"", /* NT Service Dependencies */
"Server", /* NT application Name */
"", /* NT Service Dependencies */
/*
* handle incoming connect requests.
* The dynamic mode is a bit tricky mostly because we want to avoid
/*
* handle incoming connect requests.
* The dynamic mode is a bit tricky mostly because we want to avoid
yaz_log(LOG_DEBUG, "Setting timeout %d", control_block.idle_timeout);
iochan_setdata(new_chan, newas);
yaz_log(LOG_DEBUG, "Setting timeout %d", control_block.idle_timeout);
iochan_setdata(new_chan, newas);
if (control_block.bend_stop)
(*control_block.bend_stop)(&control_block);
for (p = pListener; p; p = p->next)
if (control_block.bend_stop)
(*control_block.bend_stop)(&control_block);
for (p = pListener; p; p = p->next)
}
sprintf(nbuf, "%s(%d)", me, getpid());
yaz_log_init(control_block.loglevel, nbuf, 0);
}
sprintf(nbuf, "%s(%d)", me, getpid());
yaz_log_init(control_block.loglevel, nbuf, 0);
if ((res = cs_listen_check(line, 0, 0, control_block.check_ip,
control_block.daemon_name)) < 0)
{
if ((res = cs_listen_check(line, 0, 0, control_block.check_ip,
control_block.daemon_name)) < 0)
{
newas->cs_get_mask = cs_get_mask;
iochan_setdata(new_chan, newas);
newas->cs_get_mask = cs_get_mask;
iochan_setdata(new_chan, newas);
yaz_log(LOG_LOG, "Starting session %d from %s",
no_sessions, a ? a : "[Unknown]");
yaz_log(LOG_LOG, "Starting session %d from %s",
no_sessions, a ? a : "[Unknown]");
if ((assoc = create_association(chan, line)))
{
iochan_setdata(chan, assoc);
if ((assoc = create_association(chan, line)))
{
iochan_setdata(chan, assoc);
addr = cs_addrstr(line);
yaz_log(LOG_LOG, "Inetd association from %s",
addr ? addr : "[UNKNOWN]");
addr = cs_addrstr(line);
yaz_log(LOG_LOG, "Inetd association from %s",
addr ? addr : "[UNKNOWN]");
- logf (LOG_LOG, "Starting server %s pid=%d", me, getpid());
+ yaz_log (LOG_LOG, "Starting server %s pid=%d", me, getpid());
- while ((ret = options("1a:iszSTl:v:u:c:w:t:k:d:", argv, argc, &arg)) != -2)
+ while ((ret = options("1a:iszSTl:v:u:c:w:t:k:d:D:", argv, argc, &arg)) != -2)
default:
fprintf(stderr, "Usage: %s [ -a <pdufile> -v <loglevel>"
" -l <logfile> -u <user> -c <config> -t <minutes>"
default:
fprintf(stderr, "Usage: %s [ -a <pdufile> -v <loglevel>"
" -l <logfile> -u <user> -c <config> -t <minutes>"