X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4ceb1196bb688d56bbceca98c615fa7b9222ba1d..5fe143dfdfa19c4fe8e15abfa933940fb51662e5:/src/stc/stc.cpp diff --git a/src/stc/stc.cpp b/src/stc/stc.cpp index 4fb35f564e..35655c3411 100644 --- a/src/stc/stc.cpp +++ b/src/stc/stc.cpp @@ -1077,7 +1077,7 @@ void wxStyledTextCtrl::SetText(const wxString& text) { // Retrieve all the text in the document. wxString wxStyledTextCtrl::GetText() { wxString text; - int len = GetTextLength(); + int len = GetTextLength()+1; char* buff = text.GetWriteBuf(len+1); SendMsg(2182, len, (long)buff);