corrected off by 1 error in cMB2WC() call (thanks valgrind)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47691 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2007-07-24 00:36:22 +00:00
parent 89216929ee
commit 8ca1a013e4

View File

@ -458,7 +458,7 @@ wxFileConfig::wxFileConfig(wxInputStream &inStream, const wxMBConv& conv)
#if wxUSE_UNICODE
size_t len;
cbuf = conv.cMB2WC((char *)buf.GetData(), buf.GetDataLen(), &len);
cbuf = conv.cMB2WC((char *)buf.GetData(), buf.GetDataLen() + 1, &len);
if ( !len && buf.GetDataLen() )
{
wxLogError(_("Failed to read config options."));