shell: Don't launch a new screensaver if the old one is still running

This commit is contained in:
Kristian Høgsberg 2012-03-01 17:11:36 -05:00
parent 525696851e
commit 32bed57d5a
1 changed files with 5 additions and 0 deletions

View File

@ -885,6 +885,11 @@ launch_screensaver(struct wl_shell *shell)
if (!shell->screensaver.path) if (!shell->screensaver.path)
return; return;
if (shell->screensaver.process.pid != 0) {
fprintf(stderr, "old screensaver still running\n");
return;
}
weston_client_launch(shell->compositor, weston_client_launch(shell->compositor,
&shell->screensaver.process, &shell->screensaver.process,
shell->screensaver.path, shell->screensaver.path,