41a6c3
diff --git a/support/rotatelogs.c b/support/rotatelogs.c
41a6c3
index 55c4406..f4c6490 100644
41a6c3
--- a/support/rotatelogs.c
41a6c3
+++ b/support/rotatelogs.c
41a6c3
@@ -49,6 +49,7 @@
41a6c3
 #include "apr_time.h"
41a6c3
 #include "apr_getopt.h"
41a6c3
 #include "apr_thread_proc.h"
41a6c3
+#include "apr_signal.h"
41a6c3
 #if APR_FILES_AS_SOCKETS
41a6c3
 #include "apr_poll.h"
41a6c3
 #endif
41a6c3
@@ -595,6 +596,10 @@ int main (int argc, const char * const argv[])
41a6c3
             break;
41a6c3
         case 'p':
41a6c3
             config.postrotate_prog = opt_arg;
41a6c3
+#ifdef SIGCHLD
41a6c3
+            /* Prevent creation of zombies (on modern Unix systems). */
41a6c3
+            apr_signal(SIGCHLD, SIG_IGN);
41a6c3
+#endif
41a6c3
             break;
41a6c3
         case 'f':
41a6c3
             config.force_open = 1;