X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f172cb8200f08ba1c6735a0d507991c877c0d68f..9e50ed28d99a07bff5f63c9f7952c3ae6be6cab0:/src/common/stringimpl.cpp diff --git a/src/common/stringimpl.cpp b/src/common/stringimpl.cpp index 4c30917521..d626556df9 100644 --- a/src/common/stringimpl.cpp +++ b/src/common/stringimpl.cpp @@ -180,7 +180,7 @@ wxStringImpl::wxStringImpl(const_iterator first, const_iterator last) { if ( last >= first ) { - InitWith(first, 0, last - first); + InitWith(first.GetPtr(), 0, last - first); } else { @@ -207,8 +207,8 @@ bool wxStringImpl::AllocBuffer(size_t nLen) wxASSERT( nLen > 0 ); // make sure that we don't overflow - wxASSERT( nLen < (INT_MAX / sizeof(wxStringCharType)) - - (sizeof(wxStringData) + EXTRA_ALLOC + 1) ); + wxCHECK( nLen < (INT_MAX / sizeof(wxStringCharType)) - + (sizeof(wxStringData) + EXTRA_ALLOC + 1), false ); STATISTICS_ADD(Length, nLen);