Mercurial > sdl-ios-xcode
diff src/events/SDL_keyboard.c @ 1612:97d0966f4bf7
Fixed some ultra-pedantic gcc warnings
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Fri, 24 Mar 2006 06:10:24 +0000 |
parents | 1ff64ad478b2 |
children | 14717b52abc0 |
line wrap: on
line diff
--- a/src/events/SDL_keyboard.c Fri Mar 24 05:11:51 2006 +0000 +++ b/src/events/SDL_keyboard.c Fri Mar 24 06:10:24 2006 +0000 @@ -34,7 +34,7 @@ static SDLMod SDL_ModState; int SDL_TranslateUNICODE = 0; -static char *keynames[SDLK_LAST]; /* Array of keycode names */ +static const char *keynames[SDLK_LAST]; /* Array of keycode names */ /* * jk 991215 - added @@ -356,7 +356,7 @@ char *SDL_GetKeyName(SDLKey key) { - char *keyname; + const char *keyname; keyname = NULL; if ( key < SDLK_LAST ) { @@ -365,7 +365,8 @@ if ( keyname == NULL ) { keyname = "unknown key"; } - return(keyname); + /* FIXME: make this function const in 1.3 */ + return (char *)(keyname); } /* These are global for SDL_eventloop.c */