From 07b24459ea4f06f7e86b7c4557eea5b451354575 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Igor=20B=C3=B6hm?= Date: Sat, 25 Jul 2020 21:54:02 +0200 Subject: [PATCH] Bail out if convW2M(...) indicates failure. --- src/libdraw/event.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/libdraw/event.c b/src/libdraw/event.c index da432db5..0b29a088 100644 --- a/src/libdraw/event.c +++ b/src/libdraw/event.c @@ -207,7 +207,8 @@ startrpc(int type) Wsysmsg w; w.type = type; - convW2M(&w, buf, sizeof buf); + if(convW2M(&w, buf, sizeof buf) == 0) + return nil; return muxrpcstart(display->mux, buf); }