tFix for odd behaviour after fork() when using the SDL plugin. - vaccinewars - be a doctor and try to vaccinate the world
 (HTM) git clone git://src.adamsgaard.dk/vaccinewars
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit 74b39dc9b927406a5023f1de4f4bacb98b03e4cc
 (DIR) parent 38ffefd3a56c63ece9ed2fe03e9d8371565cb3ae
 (HTM) Author: Ben Webb <ben@salilab.org>
       Date:   Tue, 25 Jun 2002 10:31:21 +0000
       
       Fix for odd behaviour after fork() when using the SDL plugin.
       
       
       Diffstat:
         M src/gtkport/gtkport.c               |       6 +++---
       
       1 file changed, 3 insertions(+), 3 deletions(-)
       ---
 (DIR) diff --git a/src/gtkport/gtkport.c b/src/gtkport/gtkport.c
       t@@ -5288,15 +5288,15 @@ static gboolean gtk_url_triggered(GtkWidget *widget, GdkEventButton *event,
            /* Fork twice so that the spawned process gets init as its parent */
            pid = fork();
            if (pid > 0) {
       -      waitpid(-1, &status, WNOHANG);
       +      wait(&status);
            } else if (pid == 0) {
              pid = fork();
              if (pid == 0) {
                execv(bin, args);
                g_print("dopewars: cannot execute %s\n", bin);
       -        exit(1);
       +        _exit(1);
              } else {
       -        exit(0);
       +        _exit(0);
              }
            }
          }