From 471aebdd3e7aef32773a2a99ff47f8f0cf564696 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 5 Jan 1999 22:53:29 +0000 Subject: [PATCH] bug in wxString::Printf() corrected (the length of the string wasn't updated correctly) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1323 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/string.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/common/string.cpp b/src/common/string.cpp index 9d05639046..03e3ac1516 100644 --- a/src/common/string.cpp +++ b/src/common/string.cpp @@ -345,6 +345,10 @@ void wxString::AllocBeforeWrite(size_t nLen) pData->Unlock(); AllocBuffer(nLen); } + else { + // update the string length + pData->nDataLength = nLen; + } wxASSERT( !GetStringData()->IsShared() ); // we must be the only owner } -- 2.50.0