From: <ny...@us...> - 2006-07-02 11:51:42
|
Revision: 106 Author: nyaochi Date: 2006-07-02 04:51:36 -0700 (Sun, 02 Jul 2006) ViewCVS: http://svn.sourceforge.net/pmplib/?rev=106&view=rev Log Message: ----------- I was surprised to see that the code did not use the character encodings specified by -w and -e options. The previous code was fixed to CP932 (Shift_JIS Japanese) encoding, which is compatible with US-ASCII. Modified Paths: -------------- trunk/frontend/easypmp/cui/main.c trunk/frontend/easypmp/cui/option.c Modified: trunk/frontend/easypmp/cui/main.c =================================================================== --- trunk/frontend/easypmp/cui/main.c 2006-07-02 11:21:46 UTC (rev 105) +++ trunk/frontend/easypmp/cui/main.c 2006-07-02 11:51:36 UTC (rev 106) @@ -217,11 +217,11 @@ #ifndef _WIN32 if (opt.system_encoding) { + set_encoding(opt.system_encoding); } - set_encoding("CP932"); if (opt.music_encoding) { + set_encoding_music(opt.music_encoding); } - set_encoding_music("CP932"); #endif/*_WIN32*/ /* Obtain the path to root directory (path_to_root) from the command line if any. */ Modified: trunk/frontend/easypmp/cui/option.c =================================================================== --- trunk/frontend/easypmp/cui/option.c 2006-07-02 11:21:46 UTC (rev 105) +++ trunk/frontend/easypmp/cui/option.c 2006-07-02 11:51:36 UTC (rev 106) @@ -203,9 +203,11 @@ break; #ifndef _WIN32 case 'e': - opt->system_encoding = optarg; + free(opt->system_encoding); + opt->system_encoding = strdup(optarg); break; case 'w': + free(opt->music_encoding); opt->music_encoding = optarg; break; #endif/*_WIN32*/ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |