X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Ftcpip.c;h=02353c98de46b0d888c32bb6257e90bf4713119c;hb=3ee7ef4088b265faffbdcabe3eb13d5f04a3b832;hp=db0e834b77352e191623f4c308233aae8cde9cb5;hpb=fb6d99a0c7e07d9cc4a315c447deaf6564a85505;p=yaz-moved-to-github.git diff --git a/src/tcpip.c b/src/tcpip.c index db0e834..02353c9 100644 --- a/src/tcpip.c +++ b/src/tcpip.c @@ -2,7 +2,7 @@ * Copyright (C) 1995-2005, Index Data ApS * See the file LICENSE for details. * - * $Id: tcpip.c,v 1.16 2005-06-25 15:46:06 adam Exp $ + * $Id: tcpip.c,v 1.18 2006-06-09 12:40:53 adam Exp $ */ /** * \file tcpip.c @@ -490,8 +490,7 @@ static int tcpip_bind(COMSTACK h, void *address, int mode) if (sp->ctx_alloc) { int res; - res = SSL_CTX_use_certificate_file (sp->ctx, sp->cert_fname, - SSL_FILETYPE_PEM); + res = SSL_CTX_use_certificate_chain_file(sp->ctx, sp->cert_fname); if (res <= 0) { ERR_print_errors_fp(stderr); @@ -534,7 +533,8 @@ static int tcpip_bind(COMSTACK h, void *address, int mode) h->cerrno = CSYSERR; return -1; } - if (mode == CS_SERVER && listen(h->iofile, 3) < 0) + /* Allow a maximum-sized backlog of waiting-to-connect clients */ + if (mode == CS_SERVER && listen(h->iofile, SOMAXCONN) < 0) { h->cerrno = CSYSERR; return -1;