Fixed bug #797
authorSam Lantinga
Sat, 26 Sep 2009 10:36:55 +0000
changeset 3320b225c8a7896e
parent 3319 63d4517fc4ac
child 3321 714a352c8869
Fixed bug #797

Ryan C. Gordon 2009-09-19 08:25:21 PDT

This line in SDL_iconv_string (src/stdlib/SDL_iconv.c) ...

if (!fromcode || !*fromcode) {
tocode = "UTF-8";
}

Is probably supposed to assign to "fromcode" and not "tocode".
src/stdlib/SDL_iconv.c
     1.1 --- a/src/stdlib/SDL_iconv.c	Sat Sep 26 10:32:14 2009 +0000
     1.2 +++ b/src/stdlib/SDL_iconv.c	Sat Sep 26 10:36:55 2009 +0000
     1.3 @@ -832,7 +832,7 @@
     1.4              tocode = "UTF-8";
     1.5          }
     1.6          if (!fromcode || !*fromcode) {
     1.7 -            tocode = "UTF-8";
     1.8 +            fromcode = "UTF-8";
     1.9          }
    1.10          cd = SDL_iconv_open(tocode, fromcode);
    1.11      }