--On Monday, March 29, 2004 16:42:09 +0200 Pontus Skoeld <[EMAIL PROTECTED]> wrote:

I've recently tried rsync in daemon mode on AIX. Unfortunately, after
handling connections, the daemon segfaulted. I've located this problem
to the signal handler for SIGCHLD in socket.c - it seems reinstalling
the signal handler before doing waitpid caused the signal to be
redelivered, so the program recurses to the signal handler before it
runs out of stack space in the end and segfaults. Simply moving the
handler reinstaller to after the waitpid seems to work (and should,
AFAIK not break anything on other systems).

Blech. Why is rsync not just using sigaction()? It's the _only_ way to get cross-platform reliable signals. SYSV/BSD signal() is just too broken on too many platforms.


If it would be accepted, I'd happily submit a patch fixing up signal handling to only use the nice, functional POSIX API.

--
Carson



--
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html

Reply via email to