weston-launch: Don't exit on SIGTERM
authorKristian Høgsberg <krh@bitplanet.net>
Mon, 17 Jun 2013 19:23:20 +0000 (15:23 -0400)
committerKristian Høgsberg <krh@bitplanet.net>
Mon, 17 Jun 2013 19:46:07 +0000 (15:46 -0400)
Instead, forward signal to weston and wait for weston to clean up nicely.
Weston relies on weston-launch being around to shut down correctly,
so don't exit until we get the SIGCHLD from weston.  This make
killall weston-launch work properly.

https://bugs.freedesktop.org/show_bug.cgi?id=62910

src/weston-launch.c

index de4e705..76dcede 100644 (file)
@@ -453,13 +453,9 @@ handle_signal(struct weston_launch *wl)
                }
                break;
        case SIGTERM:
-               if (wl->child)
-                       kill(wl->child, SIGTERM);
-               quit(wl, 0);
-               break;
        case SIGINT:
                if (wl->child)
-                       kill(wl->child, SIGTERM);
+                       kill(wl->child, sig.ssi_signo);
                break;
        default:
                return -1;