1. We have moved from vBulletin to XenForo and you are viewing the site in the middle of the move. Though the functional aspect of everything is working fine, we are still working on other changes including the new design on Xenforo.
    Dismiss Notice

Help! SIGCHLD is causing parent to terminate

Discussion in 'C' started by KeithL, Mar 16, 2008.

  1. KeithL

    KeithL New Member

    Hi everyone,
    This is my first time posting in these forums.

    I have built a file transfer application, the server is coded in C (on Solaris), and the client application is coded in Java (on Windows).
    The server forks a child for every client, and whenever the client closes the application, the parent process is notified and executes the SIGCHLD handler function.

    However, once that function is executed, the parent terminates, and obviously, any incoming connections are then refused.
    Is this behaviour typical of the signal handlers, or am I missing something. Is there a possible workaround for it?

    Any suggestions are very welcome. Thanks in advance.

Share This Page