X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/93210c68cb8ad36a5b2d7f07e93735041657c534..90c108964caba82a62602c7eef1268d4bb6e4841:/contrib/src/ogl/divided.cpp diff --git a/contrib/src/ogl/divided.cpp b/contrib/src/ogl/divided.cpp index 50737984c0..9d682b8120 100644 --- a/contrib/src/ogl/divided.cpp +++ b/contrib/src/ogl/divided.cpp @@ -700,9 +700,8 @@ void wxDividedShapeControlPoint::OnEndDragLeft(double WXUNUSED(x), double y, int wxShapeRegion *region = (wxShapeRegion *)node->GetData(); if (region->GetText()) { - wxChar *s = copystring(region->GetText()); - dividedObject->FormatText(dc, s, i); - delete[] s; + wxString s(region->GetText()); + dividedObject->FormatText(dc, s.c_str(), i); } node = node->GetNext(); i++;