From 8874d1fe214129abeb9c3cce586aa330a8847f4b Mon Sep 17 00:00:00 2001 From: Stefan Csomor Date: Thu, 28 May 2009 10:50:58 +0000 Subject: [PATCH] backport of fix for non-unicode, stl-enable git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_9_0_BRANCH@60780 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/fs_mem.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/common/fs_mem.cpp b/src/common/fs_mem.cpp index 9cd5628f86..3ad28089e6 100644 --- a/src/common/fs_mem.cpp +++ b/src/common/fs_mem.cpp @@ -186,9 +186,13 @@ void wxMemoryFSHandlerBase::AddFileWithMimeType(const wxString& filename, const wxString& textdata, const wxString& mimetype) { - AddFileWithMimeType(filename, - (const void*) textdata.mb_str(), textdata.length(), - mimetype); + AddFileWithMimeType + ( + filename, + static_cast(textdata.To8BitData()), + wxStrlen(static_cast(textdata.To8BitData())), + mimetype + ); }