From eb140739dbc26a0331b16b12081f1dae3847c9bb Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Sat, 13 Feb 2010 13:37:08 +0000 Subject: CID-138 Checker: NULL_RETURNS Function: LLPanelFace::sendGlow() File: /indra/newview/llpanelface.cpp --- indra/newview/llpanelface.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'indra/newview/llpanelface.cpp') diff --git a/indra/newview/llpanelface.cpp b/indra/newview/llpanelface.cpp index 8c5208678e..4f450ce0a8 100644 --- a/indra/newview/llpanelface.cpp +++ b/indra/newview/llpanelface.cpp @@ -265,10 +265,13 @@ void LLPanelFace::sendAlpha() void LLPanelFace::sendGlow() { - LLSpinCtrl* mCtrlGlow = getChild("glow"); - F32 glow = mCtrlGlow->get(); - - LLSelectMgr::getInstance()->selectionSetGlow( glow ); + LLSpinCtrl* mCtrlGlow = getChild("glow"); + llassert(mCtrlGlow); + if (mCtrlGlow) + { + F32 glow = mCtrlGlow->get(); + LLSelectMgr::getInstance()->selectionSetGlow( glow ); + } } struct LLPanelFaceSetTEFunctor : public LLSelectedTEFunctor -- cgit v1.2.3 From 10c9f17301e2dbacb0105b29d7214e67d5de8e85 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Sat, 13 Feb 2010 13:40:45 +0000 Subject: CID-139 Checker: NULL_RETURNS Function: LLPanelFaceSetTEFunctor::apply(LLViewerObject *, int) File: /indra/newview/llpanelface.cpp --- indra/newview/llpanelface.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'indra/newview/llpanelface.cpp') diff --git a/indra/newview/llpanelface.cpp b/indra/newview/llpanelface.cpp index 4f450ce0a8..b50c6442e1 100644 --- a/indra/newview/llpanelface.cpp +++ b/indra/newview/llpanelface.cpp @@ -289,6 +289,9 @@ struct LLPanelFaceSetTEFunctor : public LLSelectedTEFunctor LLCheckBoxCtrl* checkFlipScaleS = mPanel->getChild("checkbox flip s"); LLCheckBoxCtrl* checkFlipScaleT = mPanel->getChild("checkbox flip t"); LLComboBox* comboTexGen = mPanel->getChild("combobox texgen"); + llassert(comboTexGen); + llassert(object); + if (ctrlTexScaleS) { valid = !ctrlTexScaleS->getTentative() || !checkFlipScaleS->getTentative(); @@ -299,7 +302,8 @@ struct LLPanelFaceSetTEFunctor : public LLSelectedTEFunctor { value = -value; } - if (comboTexGen->getCurrentIndex() == 1) + if (comboTexGen && + comboTexGen->getCurrentIndex() == 1) { value *= 0.5f; } @@ -317,7 +321,8 @@ struct LLPanelFaceSetTEFunctor : public LLSelectedTEFunctor { value = -value; } - if (comboTexGen->getCurrentIndex() == 1) + if (comboTexGen && + comboTexGen->getCurrentIndex() == 1) { value *= 0.5f; } -- cgit v1.2.3