Changeset 294
- Timestamp:
- 01/15/15 22:38:08 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/common/Convert.cpp
r286 r294 153 153 wstring wstr; 154 154 int nOffset = 0; 155 int nDataLen = strlen(str) + 1; //including ending \0155 int nDataLen = strlen(str); //ending \0 is not converted, but resize() below sets the proper length of wstr 156 156 int nLenWide = MultiByteToWideChar(CP_UTF8, 0, (LPCSTR)(str + nOffset), 157 157 (int)(nDataLen - nOffset), NULL, 0); … … 162 162 { 163 163 //ASSERT(false); //some conversion error 164 return wstr ;164 return wstr + L"<UTF8_CONV_ERROR>"; 165 165 } 166 166 return wstr;
Note: See TracChangeset
for help on using the changeset viewer.