src/events/SDL_keyboard.c
changeset 2229 22342048bcb8
parent 2129 047245361002
child 2268 4baee598306d
     1.1 --- a/src/events/SDL_keyboard.c	Sun Aug 12 00:01:41 2007 +0000
     1.2 +++ b/src/events/SDL_keyboard.c	Sun Aug 12 05:48:51 2007 +0000
     1.3 @@ -448,9 +448,11 @@
     1.4              char *cvt;
     1.5              temp[0] = (char) key;
     1.6              temp[1] = '\0';
     1.7 -            cvt = SDL_iconv_string("UTF-8", "LATIN1", temp, 1);
     1.8 -            SDL_strlcpy(temp, cvt, SDL_arraysize(temp));
     1.9 -            SDL_free(cvt);
    1.10 +            cvt = SDL_iconv_string("UTF-8", "ISO-8859-1", temp, 1);
    1.11 +            if (cvt) {
    1.12 +                SDL_strlcpy(temp, cvt, SDL_arraysize(temp));
    1.13 +                SDL_free(cvt);
    1.14 +            }
    1.15              keyname = temp;
    1.16          } else {
    1.17              keyname = "unknown key";