--- hatari/src/gui-sdl/dlgJoystick.c 2019/04/01 07:12:47 1.1.1.3 +++ hatari/src/gui-sdl/dlgJoystick.c 2019/04/01 07:13:15 1.1.1.4 @@ -4,7 +4,7 @@ This file is distributed under the GNU Public License, version 2 or at your option any later version. Read the file gpl.txt for details. */ -char DlgJoystick_rcsid[] = "Hatari $Id: dlgJoystick.c,v 1.1.1.3 2019/04/01 07:12:47 root Exp $"; +const char DlgJoystick_rcsid[] = "Hatari $Id: dlgJoystick.c,v 1.1.1.4 2019/04/01 07:13:15 root Exp $"; #include "main.h" #include "configuration.h" @@ -72,7 +72,7 @@ static SGOBJ joykeysdlg[] = }; -static char *sJoystickNames[6] = +static char *sJoystickNames[JOYSTICK_COUNT] = { "ST Joystick 0", "ST Joystick 1", @@ -219,7 +219,7 @@ void Dialog_JoyDlg(void) switch (but) { case DLGJOY_PREVSDLJOY: // Select the previous SDL joystick - if (DialogParams.Joysticks.Joy[nActJoy].nJoyId > '0') + if (DialogParams.Joysticks.Joy[nActJoy].nJoyId > 0) { DialogParams.Joysticks.Joy[nActJoy].nJoyId -= 1; snprintf(sSdlStickName, 20, "%i: %s", DialogParams.Joysticks.Joy[nActJoy].nJoyId,