From 728d09936f76ce60090e0fd0505b0522d03dd535 Mon Sep 17 00:00:00 2001 From: Casey Dahlin Date: Mon, 18 Jul 2011 02:00:24 -0400 Subject: [PATCH] Fix segfault in client when demarshalling fails --- wayland/wayland-client.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/wayland/wayland-client.c b/wayland/wayland-client.c index ce27a90..9d1f66b 100644 --- a/wayland/wayland-client.c +++ b/wayland/wayland-client.c @@ -521,6 +521,11 @@ handle_event(struct wl_display *display, closure = wl_connection_demarshal(display->connection, size, display->objects, message); + if (closure == NULL) { + fprintf(stderr, "Error demarshalling event: %m\n"); + abort(); + } + if (wl_debug) wl_closure_print(closure, &proxy->object, false); -- 2.7.4