added null pointer check and assert

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@49928 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Benjamin Williams
2007-11-13 20:18:30 +00:00
parent 466c0ffd61
commit c36cdfc084

View File

@@ -3064,6 +3064,10 @@ bool wxAuiNotebook::InsertPage(size_t page_idx,
bool select,
const wxBitmap& bitmap)
{
wxASSERT_MSG(page, wxT("page pointer must be non-NULL"));
if (!page)
return false;
page->Reparent(this);
wxAuiNotebookPage info;