From: Ihar Hrachyshka Date: Wed, 21 Jul 2010 05:43:01 +0000 (+0200) Subject: screen_help: remove CMD_SCREEN_SONG if song screen is disabled X-Git-Tag: release-0.18~14 X-Git-Url: https://git.tokkee.org/?p=ncmpc.git;a=commitdiff_plain;h=0cc3e108a34ea669c1edafb55574fef1e10409c1 screen_help: remove CMD_SCREEN_SONG if song screen is disabled This fixes a NULL pointer dereference, caused by get_key_names(CMD_SCREEN_SONG)==NULL. --- diff --git a/src/screen_help.c b/src/screen_help.c index 2ac90b7..faa9603 100644 --- a/src/screen_help.c +++ b/src/screen_help.c @@ -105,7 +105,9 @@ static const struct help_text_row help_text[] = { { 0, CMD_LIST_JUMP, NULL }, { 0, CMD_TOGGLE_FIND_WRAP, NULL }, { 0, CMD_LOCATE, NULL }, +#ifdef ENABLE_SONG_SCREEN { 0, CMD_SCREEN_SONG, NULL }, +#endif { 0, CMD_NONE, NULL }, { 0, CMD_QUIT, NULL },