undid last (wrong) change to wxMBConvUTF16swap::MB2WC(); added comment to explain why
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38489 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -864,7 +864,9 @@ size_t wxMBConvUTF16swap::MB2WC(wchar_t *buf, const char *psz, size_t n) const
|
|||||||
{
|
{
|
||||||
size_t len = 0;
|
size_t len = 0;
|
||||||
|
|
||||||
while ( *psz && (!buf || len < n) )
|
// UTF16 string must be terminated by 2 NULs as single NULs may occur
|
||||||
|
// inside the string
|
||||||
|
while ( (psz[0] || psz[1]) && (!buf || len < n) )
|
||||||
{
|
{
|
||||||
if ( buf )
|
if ( buf )
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user