From 9dccf621c835f9ca7364bf28724d72402e90165e Mon Sep 17 00:00:00 2001 From: Paul Cornett Date: Fri, 26 Feb 2016 10:39:02 -0800 Subject: [PATCH] Avoid comparing address of reference to NULL (backport of 01ccff2e05128241827935646cbb275bab05223b) --- src/propgrid/property.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/propgrid/property.cpp b/src/propgrid/property.cpp index 5067b8d2e7..72a7a51530 100644 --- a/src/propgrid/property.cpp +++ b/src/propgrid/property.cpp @@ -477,13 +477,13 @@ void wxPGProperty::Init() void wxPGProperty::Init( const wxString& label, const wxString& name ) { - // We really need to check if &label and &name are NULL pointers - // (this can if we are called before property grid has been initalized) + // wxPG_LABEL reference can be NULL if we are called before property + // grid has been initialized - if ( (&label) != NULL && label != wxPG_LABEL ) + if ( sm_wxPG_LABEL && label != wxPG_LABEL ) m_label = label; - if ( (&name) != NULL && name != wxPG_LABEL ) + if ( sm_wxPG_LABEL && name != wxPG_LABEL ) DoSetName( name ); else DoSetName( m_label );