Revision: 8197 Author: [email protected] Date: Tue Jun 7 04:53:49 2011 Log: Convert time zone name to UTF8 on Windows.
[email protected] BUG=v8:1290 Review URL: http://codereview.chromium.org/7125008 http://code.google.com/p/v8/source/detail?r=8197 Modified: /branches/bleeding_edge/src/platform-win32.cc ======================================= --- /branches/bleeding_edge/src/platform-win32.cc Tue Jun 7 00:17:46 2011 +++ /branches/bleeding_edge/src/platform-win32.cc Tue Jun 7 04:53:49 2011 @@ -412,13 +412,11 @@ } // Make standard and DST timezone names. - OS::SNPrintF(Vector<char>(std_tz_name_, kTzNameSize), - "%S", - tzinfo_.StandardName); + WideCharToMultiByte(CP_UTF8, 0, tzinfo_.StandardName, -1, + std_tz_name_, kTzNameSize, NULL, NULL); std_tz_name_[kTzNameSize - 1] = '\0'; - OS::SNPrintF(Vector<char>(dst_tz_name_, kTzNameSize), - "%S", - tzinfo_.DaylightName); + WideCharToMultiByte(CP_UTF8, 0, tzinfo_.DaylightName, -1, + dst_tz_name_, kTzNameSize, NULL, NULL); dst_tz_name_[kTzNameSize - 1] = '\0'; // If OS returned empty string or resource id (like "@tzres.dll,-211") -- v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev
