X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Funix.c;h=60cbedc3e7dadb758c0bf9623fa1187e058bc46b;hb=00537b483d646bd04a204708ecbde708861f044e;hp=e37bf70cf9c7924fe34407c6d466da6bbb48bb6d;hpb=4a9cbf62bc7a294f1782386997e09d2dd4ba9671;p=yaz-moved-to-github.git diff --git a/src/unix.c b/src/unix.c index e37bf70..60cbedc 100644 --- a/src/unix.c +++ b/src/unix.c @@ -1,11 +1,14 @@ /* This file is part of the YAZ toolkit. - * Copyright (C) 1995-2009 Index Data + * Copyright (C) 1995-2012 Index Data * See the file LICENSE for details. */ /** * \file unix.c * \brief Implements UNIX domain socket COMSTACK */ +#if HAVE_CONFIG_H +#include +#endif #ifndef WIN32 @@ -244,7 +247,7 @@ static void *unix_straddr1(COMSTACK h, const char *str, char *f) { char * end; char * arg = s + 6; - + sp->umask = strtol(arg, &end, 8); if (errno == EINVAL || *end) @@ -510,7 +513,7 @@ static COMSTACK unix_accept(COMSTACK h) } return 0; } - if (!(cnew->flags&CS_FLAGS_BLOCKING) && + if (!(cnew->flags&CS_FLAGS_BLOCKING) && (fcntl(cnew->iofile, F_SETFL, O_NONBLOCK) < 0) ) {