From: Andre Noll Date: Mon, 13 May 2024 21:32:52 +0000 (+0200) Subject: play.c: Replace NULL check by assertion. X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=4e7de83d81baee96116e823f29926222661ceb15;p=paraslash.git play.c: Replace NULL check by assertion. If p is NULL, kma contains no colon, and we should not be here in the first place. Instead, we should have errored out much earlier in the command line parser. Suggested-by: gcc(1) --- diff --git a/play.c b/play.c index bd183b6b..4adedcc0 100644 --- a/play.c +++ b/play.c @@ -580,8 +580,7 @@ static char *get_user_key_map_seq(int key) char *result; int len; - if (!p) - return NULL; + assert(p); len = p - kma; result = alloc(len + 1); memcpy(result, kma, len);