Oleg,

try the attached patch.


UEMURA (fka. MAENAKA) Tetsuya wrote:
> Posted on Mon, 13 Nov 2006 11:37:56 +0300
> by author Oleg Albegov <[EMAIL PROTECTED]>
>> I think, i have the latest..
>>
>> [EMAIL PROTECTED] /usr/ports/devel/autoconf259]# pkg_info | grep auto
>> autoconf-2.59_2     Automatically configure source code on many Un*x 
>> platforms
>> automake-1.9.6      GNU Standards-compliant Makefile generator (1.9)
> 
> If you have installed autoconf259, automake19 and libtool, all from the
> ports, then the following will generate the configure.
> 
> cd dbmail_2_2_branch
> cat /usr/local/share/aclocal/libtool.m4 >> acinclude.m4
> ACLOCAL=aclocal19 AUTOCONF=autoconf259 AUTOHEADER=autoheader259 \
> AUTOM4TE=autom4te259 AUTOMAKE=automake19 AUTORECONF=autoreconf259 \
> AUTOSCAN=autoscan259 AUTOUPDATE=autoupdate259 LIBTOOL=libtool \
> LIBTOOLIZE=libtoolize autoreconf259 -f -i
> 

-- 
  ________________________________________________________________
  Paul Stevens                                      paul at nfg.nl
  NET FACILITIES GROUP                     GPG/PGP: 1024D/11F8CD31
  The Netherlands________________________________http://www.nfg.nl
Index: serverchild.c
===================================================================
--- serverchild.c       (revision 2366)
+++ serverchild.c       (working copy)
@@ -270,14 +270,15 @@
        // accept will block forever unless it is set non-blocking with fcntl,
        // so we have to do this dance to make it temporarily non-blocking.
        *clientSocket = accept(info->listenSockets[active], saClient, &len);
-       if (*clientSocket < 0) 
-               serr = errno;
+       // on some systems (freebsd) the non-blocking state is inherited by
+       // the new socket, so we want to reset both the new socket and the 
listening
+       // handle.
+       if (*clientSocket > 0) 
+               fcntl(*clientSocket, F_SETFL, flags);
        fcntl(info->listenSockets[active], F_SETFL, flags);
 
-       if (*clientSocket < 0) {
-               TRACE(TRACE_ERROR, "accept failed: [%s]", strerror(serr));
+       if (*clientSocket < 0)
                return -1;
-       }
 
        TRACE(TRACE_INFO, "connection accepted");
        return 0;

Reply via email to