MAINT-5435 missing null check

Fri, 04 Mar 2016 18:22:08 +0200

author
andreykproductengine <akleshchev@productengine.com>
date
Fri, 04 Mar 2016 18:22:08 +0200
changeset 48909
16f91253ce49
parent 48908
7d463d571eeb
child 48915
b11d9da3c1bf

MAINT-5435 missing null check

indra/newview/llfloatersidepanelcontainer.cpp file | annotate | diff | revisions
indra/newview/llsidepanelappearance.cpp file | annotate | diff | revisions
     1.1 --- a/indra/newview/llfloatersidepanelcontainer.cpp	Wed Mar 02 16:58:50 2016 +0200
     1.2 +++ b/indra/newview/llfloatersidepanelcontainer.cpp	Fri Mar 04 18:22:08 2016 +0200
     1.3 @@ -69,7 +69,11 @@
     1.4  			LLSidepanelAppearance* panel_appearance = dynamic_cast<LLSidepanelAppearance*>(getPanel("appearance"));
     1.5  			if ( panel_appearance )
     1.6  			{
     1.7 -				panel_appearance->getWearable()->onClose();
     1.8 +				LLPanelEditWearable *edit_wearable_ptr = panel_appearance->getWearable();
     1.9 +				if (edit_wearable_ptr)
    1.10 +				{
    1.11 +					edit_wearable_ptr->onClose();
    1.12 +				}
    1.13  				panel_appearance->showOutfitsInventoryPanel();
    1.14  			}
    1.15  		}
     2.1 --- a/indra/newview/llsidepanelappearance.cpp	Wed Mar 02 16:58:50 2016 +0200
     2.2 +++ b/indra/newview/llsidepanelappearance.cpp	Fri Mar 04 18:22:08 2016 +0200
     2.3 @@ -198,7 +198,7 @@
     2.4  
     2.5  		if (is_outfit_edit_visible || is_wearable_edit_visible)
     2.6  		{
     2.7 -			const LLViewerWearable *wearable_ptr = mEditWearable->getWearable();
     2.8 +			const LLViewerWearable *wearable_ptr = mEditWearable ? mEditWearable->getWearable() : NULL;
     2.9  			if (!wearable_ptr)
    2.10  			{
    2.11  				LL_WARNS() << "Visibility change to invalid wearable" << LL_ENDL;

mercurial