Hi

this little patch should get rid of the zombies that like to appear
especially when using the evo plugin

Armin
--- ../../multisync/src/syncengine.c    2003-09-25 20:58:39.000000000 +0200
+++ src/syncengine.c    2003-09-25 23:15:04.000000000 +0200
@@ -1,4 +1,4 @@
-/* 
+/*
    MultiSync - A PIM data synchronization program
    Copyright (C) 2002-2003 Bo Lincoln <[EMAIL PROTECTED]>
 
@@ -38,6 +38,8 @@
 #include <stdlib.h>
 #include <glib.h>
 #include <time.h>
+#include <signal.h>
+#include <sys/wait.h>
 #include "syncengine.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -1963,6 +1965,11 @@
          (objtype==SYNC_OBJECT_TYPE_PHONEBOOK?"Contact":"Unknown")));
 }
 
+void sig_child(int crap)
+{
+       waitpid(-1, NULL, WNOHANG);
+        signal(SIGCHLD,sig_child);
+}
 
 int main (int argc, char **argv)
 {
@@ -1988,6 +1995,7 @@
   textdomain (PACKAGE);
 #endif
 
+ signal(SIGCHLD,sig_child);
 
   gnome_program_init (PACKAGE, VERSION, LIBGNOMEUI_MODULE,
                       argc, argv,

Reply via email to