Ok my problem goes like this :
i'm, at the present time, writing a concurrent server communicating
with his clients through TCP/IP. One part of the code is :
        if signal(SIGCHLD, sighandler) < 0
        {
        ...
        }       
        ...
        socket(...);    /* those are classics   */
        bind(...);              
        Listen(...);                    
        while (1)
        {
                if ((sd = accept(...)) < 0)
                {
                        printf("accept error\n");
                        /*      i have to go on since its a concurrent server   */
                }
                ....
                if ((pid        = fork()) == 0)
                {
                        /* child process        */
                }
        }
I use the SIGCHLD handling to maintain a table of the running childs.
But when a child finish, (SIGCHLD is delivered to the father process)
he send me thousand "accept error" until i kill (-9) the father process.
And when i disable the SIGCHLD handling, everything is ok !
Can someone tell me why ? and what can i do ?
thanx and sorry for this litterature :-)

Gregoire Welraeds
Null coder
[EMAIL PROTECTED]

Reply via email to