From a2c3e554b4897b4e386dd4b9682af2f9117afb9b Mon Sep 17 00:00:00 2001 From: Daniel Stone Date: Tue, 1 Jul 2014 15:41:54 +0100 Subject: Don't loop forever if we can't find our interfaces Just try one wl_display_roundtrip, rather than doing them in a tight loop until we fall off the face of the planet. --- shell/maynard.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/shell/maynard.c b/shell/maynard.c index a6c7e6d..85da0fc 100644 --- a/shell/maynard.c +++ b/shell/maynard.c @@ -638,8 +638,13 @@ main (int argc, /* Wait until we have been notified about the compositor, * shell, and shell helper objects */ - while (!desktop->output || !desktop->shell || !desktop->helper) + if (!desktop->output || !desktop->shell || !desktop->helper) wl_display_roundtrip (desktop->display); + if (!desktop->output || !desktop->shell || !desktop->helper) + { + fprintf (stderr, "could not find output, shell or helper modules\n"); + return -1; + } desktop->grid_visible = FALSE; desktop->system_visible = FALSE; -- cgit v1.3.1