From 494b978fc18b48b4f16c4baf29a6645967aba30b Mon Sep 17 00:00:00 2001 From: Ryan Norton Date: Fri, 29 Oct 2004 05:52:16 +0000 Subject: [PATCH] add some asserts for wxStringBufferLength git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30157 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/string.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/include/wx/string.h b/include/wx/string.h index a31f122bcc..309b27820a 100644 --- a/include/wx/string.h +++ b/include/wx/string.h @@ -1380,7 +1380,10 @@ class WXDLLIMPEXP_BASE wxStringBufferLength public: wxStringBufferLength(wxString& str, size_t lenWanted = 1024) : m_str(str), m_buf(NULL), m_len(0), m_lenSet(false) - { m_buf = m_str.GetWriteBuf(lenWanted); } + { + m_buf = m_str.GetWriteBuf(lenWanted); + wxASSERT(m_buf != NULL); + } ~wxStringBufferLength() { -- 2.45.2