Applied patch [ 762033 ] wxTextValidator crashes when given a NULL wxString

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@21839 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2003-07-10 08:21:49 +00:00
parent f4bf101605
commit 251d904621

View File

@@ -205,6 +205,9 @@ bool wxTextValidator::TransferToWindow(void)
{
if( !CheckValidator() )
return FALSE;
if (!m_stringValue)
return TRUE;
wxTextCtrl *control = (wxTextCtrl *) m_validatorWindow ;
control->SetValue(* m_stringValue) ;
@@ -218,6 +221,9 @@ bool wxTextValidator::TransferFromWindow(void)
if( !CheckValidator() )
return FALSE;
if (!m_stringValue)
return TRUE;
wxTextCtrl *control = (wxTextCtrl *) m_validatorWindow ;
* m_stringValue = control->GetValue() ;