From ef78242e19e8d0599c74aa34fad0fbb5a56cdb20 Mon Sep 17 00:00:00 2001 From: "Daniel P. Berrange" Date: Wed, 25 Apr 2012 11:29:43 +0100 Subject: Add some more 'noreturn' annotations Methods which longjump, unconditionally raise an exception, or call _exit() cannot return control to the caller so should be annotated with 'noreturn' Signed-off-by: Daniel P. Berrange --- client/x11/platform.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'client/x11/platform.cpp') diff --git a/client/x11/platform.cpp b/client/x11/platform.cpp index 0669b69f..14c6e0cd 100644 --- a/client/x11/platform.cpp +++ b/client/x11/platform.cpp @@ -3167,11 +3167,10 @@ static int x_error_handler(Display* display, XErrorEvent* error_event) return 0; } -static int x_io_error_handler(Display* display) +static SPICE_GNUC_NORETURN int x_io_error_handler(Display* display) { LOG_ERROR("x io error on %s", XDisplayString(display)); _exit(-1); - return 0; } static XVisualInfo* get_x_vis_info(int screen) -- cgit