Comment 6 for bug 262660

Revision history for this message
Jussi Pakkanen (jpakkane) wrote :

Here is an updated patch which does not use Iconv. Please check if it works for you.

A few comments on the things I fixed.

Global variables should not be used in newly written, self-contained code. In this case it means getting rid of the GetCodePage function call and passing code page as a parameter.

Removed malloc/free. Because it is way too easy to forget the free. :)

Don't pass the character to be converted as a pointer. Only pass pointers if you intend to change the value pointed to or are dealing with structs or classes.