From 235e8eb20240af5266b064ee931bc6723004bf4d Mon Sep 17 00:00:00 2001 From: Thomas White Date: Thu, 9 Jul 2015 15:57:02 +0200 Subject: Tidy up error handling when given dodgy data locations --- src/im-sandbox.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/im-sandbox.c') diff --git a/src/im-sandbox.c b/src/im-sandbox.c index 36150a1b..f796b8b7 100644 --- a/src/im-sandbox.c +++ b/src/im-sandbox.c @@ -222,6 +222,10 @@ static struct filename_plus_event *get_pattern(FILE *fh, int config_basename, } ev_list = fill_event_list(hdfile, det); + if ( ev_list == NULL ) { + ERROR("Failed to get event list.\n"); + return NULL; + } if ( ev_list->num_events == 0 ) { event_index = -1; -- cgit v1.2.3