desktop-shell: fix invalid memory access when shell execution fails

In this case wl_client_add_destroy_listener() was called with a NULL
client, which is invalid.

Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
dev
Arnaud Vrac 10 years ago committed by Pekka Paalanen
parent 3c40f368eb
commit 4263119d02
  1. 4
      desktop-shell/shell.c

@ -5349,8 +5349,10 @@ launch_desktop_shell_process(void *data)
shell->client,
desktop_shell_sigchld);
if (!shell->child.client)
if (!shell->child.client) {
weston_log("not able to start %s\n", shell->client);
return;
}
shell->child.client_destroy_listener.notify =
desktop_shell_client_destroy;

Loading…
Cancel
Save