Fix for [ 688754 ] wxNotebook::SetSelection(-1) will segfault

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@20836 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2003-06-01 19:41:50 +00:00
parent 272995af2c
commit 65b683fd1b
2 changed files with 2 additions and 2 deletions

View File

@@ -373,7 +373,7 @@ int wxNotebook::SetSelection( int page )
{
wxCHECK_MSG( m_widget != NULL, -1, wxT("invalid notebook") );
wxCHECK_MSG( page < (int)m_pagesData.GetCount(), -1, wxT("invalid notebook index") );
wxCHECK_MSG( page >= 0 && page < (int)m_pagesData.GetCount(), -1, wxT("invalid notebook index") );
int selOld = GetSelection();