blind fix to wxGetCwd crash on NT when wxUSE_UNICODE=1 and wxUSE_UNICODE_MSLU=0

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14681 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2002-03-19 00:04:57 +00:00
parent a4f2452697
commit 247f8a77bc

View File

@@ -1458,6 +1458,11 @@ wxChar *wxGetWorkingDirectory(wxChar *buf, int sz)
#else // !Win32/VC++ !Mac !OS2
ok = getcwd(cbuf, sz) != NULL;
#endif // platform
#if wxUSE_UNICODE
// finally convert the result to Unicode if needed
wxConvFile.MB2WC(buf, cbuf, sz);
#endif // wxUSE_UNICODE
}
if ( !ok )
@@ -1487,11 +1492,6 @@ wxChar *wxGetWorkingDirectory(wxChar *buf, int sz)
wxString pathUnix = buf;
cygwin_conv_to_full_win32_path(pathUnix, buf);
#endif // __CYGWIN__
// finally convert the result to Unicode if needed
#if wxUSE_UNICODE
wxConvFile.MB2WC(buf, cbuf, sz);
#endif // wxUSE_UNICODE
}
return buf;