From 649205178fa3dfc4d6d0a6eeb5ed2919a98517d9 Mon Sep 17 00:00:00 2001 From: orbea Date: Tue, 16 May 2017 16:14:20 -0700 Subject: [PATCH] Silence a -Wnonnull warning --- frontend/drivers/platform_linux.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/frontend/drivers/platform_linux.c b/frontend/drivers/platform_linux.c index bf03b30cd4..8765fcb9ac 100644 --- a/frontend/drivers/platform_linux.c +++ b/frontend/drivers/platform_linux.c @@ -900,6 +900,9 @@ static bool next_string(char **_ptr, char **_str) static bool int_string(char *str, int *val) { + if (!str) + return false; + char *endptr = NULL; *val = (int) strtol(str, &endptr, 0); return ((*str != '\0') && (*endptr == '\0'));