X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8dffb6b1a7ddfbb22667d9544dbe11ca49ca046c..a01d6442f4dcf2d30d52e50bc8c8410066f76265:/include/wx/buffer.h diff --git a/include/wx/buffer.h b/include/wx/buffer.h index 574d0df073..4c5c27eede 100644 --- a/include/wx/buffer.h +++ b/include/wx/buffer.h @@ -95,7 +95,7 @@ public: // Creates "owned" buffer, i.e. takes over ownership of 'str' and frees it // in dtor (if ref.count reaches 0). static - const wxScopedCharTypeBuffer CreateOwned(const CharType *str, + const wxScopedCharTypeBuffer CreateOwned(CharType *str, size_t len = wxNO_LEN ) { if ( len == wxNO_LEN ) @@ -103,7 +103,7 @@ public: wxScopedCharTypeBuffer buf; if ( str ) - buf.m_data = new Data(StrCopy(str, len), len); + buf.m_data = new Data(str, len); return buf; }