From f954db02638e32677d5fe61abdf0079b434d725c Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Mon, 5 Jul 2010 11:54:50 +0100 Subject: Checker: FORWARD_NULL Function: LLChatHistory::appendMessage(const LLChat &, const LLSD &, const LLStyle::Params &) File: /indra/newview/llchathistory.cpp --- indra/newview/llchathistory.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index ac12bffdfb..c0fa910f86 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -557,11 +557,14 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL { bool use_plain_text_chat_history = args["use_plain_text_chat_history"].asBoolean(); - if(mEditor) + llassert(mEditor); + if (!mEditor) { - mEditor->setPlainText(use_plain_text_chat_history); + return; } + mEditor->setPlainText(use_plain_text_chat_history); + if (!mEditor->scrolledToEnd() && chat.mFromID != gAgent.getID() && !chat.mFromName.empty()) { mUnreadChatSources.insert(chat.mFromName); @@ -740,7 +743,7 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL mIsLastMessageFromLog = message_from_log; } - if (chat.mNotifId.notNull()) + if (chat.mNotifId.notNull()) { LLNotificationPtr notification = LLNotificationsUtil::find(chat.mNotifId); if (notification != NULL) @@ -832,6 +835,7 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL mEditor->appendText(message, FALSE, style_params); } + mEditor->blockUndo(); // automatically scroll to end when receiving chat from myself -- cgit v1.2.3 From 014c2a508934e18c347b70d905c004955cd23613 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Mon, 5 Jul 2010 11:57:45 +0100 Subject: Checker: NULL_RETURNS Function: LLPanelVoiceEffect::update(bool) File: /indra/newview/llpanelvoiceeffect.cpp --- indra/newview/llpanelvoiceeffect.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/newview') diff --git a/indra/newview/llpanelvoiceeffect.cpp b/indra/newview/llpanelvoiceeffect.cpp index fd470798ee..68fa9d1e5e 100644 --- a/indra/newview/llpanelvoiceeffect.cpp +++ b/indra/newview/llpanelvoiceeffect.cpp @@ -129,6 +129,8 @@ void LLPanelVoiceEffect::update(bool list_updated) if (mVoiceEffectCombo) { LLVoiceEffectInterface* effect_interface = LLVoiceClient::instance().getVoiceEffectInterface(); + llassert(effect_interface); + if (!effect_interface) return; if (list_updated) { // Add the default "No Voice Morph" entry. -- cgit v1.2.3 From 2888e446a723d6c477fa07fcc733dcc16e021fef Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Mon, 5 Jul 2010 12:00:02 +0100 Subject: CID-496 Checker: FORWARD_NULL Function: LLFloaterVoiceEffect::refreshEffectList() File: /indra/newview/llfloatervoiceeffect.cpp --- indra/newview/llfloatervoiceeffect.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'indra/newview') diff --git a/indra/newview/llfloatervoiceeffect.cpp b/indra/newview/llfloatervoiceeffect.cpp index ca1f142760..3ab061dbea 100644 --- a/indra/newview/llfloatervoiceeffect.cpp +++ b/indra/newview/llfloatervoiceeffect.cpp @@ -199,7 +199,12 @@ void LLFloaterVoiceEffect::refreshEffectList() if(sl_item) { LLFontGL::StyleFlags style = is_template_only ? LLFontGL::NORMAL : LLFontGL::BOLD; - dynamic_cast(sl_item->getColumn(0))->setFontStyle(style); + LLScrollListText slt = dynamic_cast(sl_item->getColumn(0)); + llassert(slt); + if (slt) + { + slt->setFontStyle(style); + } } } } -- cgit v1.2.3 From 297bab71ab6fcbdabd3f1c0ac0e2fa403a3ed319 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Mon, 5 Jul 2010 12:04:28 +0100 Subject: CID-495 Checker: FORWARD_NULL Function: show_item_original(const LLUUID &) File: /indra/newview/llinventoryfunctions.cpp --- indra/newview/llinventoryfunctions.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp index 7463658003..2d11337955 100644 --- a/indra/newview/llinventoryfunctions.cpp +++ b/indra/newview/llinventoryfunctions.cpp @@ -433,13 +433,12 @@ void show_item_original(const LLUUID& item_uuid) LLPanelMainInventory* main_inventory = floater_inventory->getMainInventoryPanel(); main_inventory->onFilterEdit(""); - } - if(floater_inventory->getVisible()) - { - floater_inventory_visible = true; + if(floater_inventory->getVisible()) + { + floater_inventory_visible = true; + } } - } if(sidepanel_inventory && !floater_inventory_visible) { -- cgit v1.2.3 From 49a3fc9cc3b47a751d99b31f87458680bd966936 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Mon, 5 Jul 2010 12:07:00 +0100 Subject: CID-494 Checker: FORWARD_NULL Function: LLPanelOutfitEdit::filterWearablesBySelectedItem() File: /indra/newview/llpaneloutfitedit.cpp --- indra/newview/llpaneloutfitedit.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview') diff --git a/indra/newview/llpaneloutfitedit.cpp b/indra/newview/llpaneloutfitedit.cpp index a7e901cbfa..053c2d9498 100644 --- a/indra/newview/llpaneloutfitedit.cpp +++ b/indra/newview/llpaneloutfitedit.cpp @@ -773,7 +773,7 @@ void LLPanelOutfitEdit::filterWearablesBySelectedItem(void) return; } - if (one_selected && !is_dummy_item) + if (item && one_selected && !is_dummy_item) { if (item->isWearableType()) { -- cgit v1.2.3 From 1ff353452174c37c600d7de650348ab30f91b86c Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Mon, 5 Jul 2010 12:17:54 +0100 Subject: CID-499 Checker: FORWARD_NULL Function: LLAppearanceMgr::dumpItemArray(const LLDynamicArray, (int)32> &, const std::basic_string, std::allocator>&) File: /indra/newview/llappearancemgr.cpp --- indra/newview/llappearancemgr.cpp | 2 +- indra/newview/llfloatervoiceeffect.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp index 8ef3fa200b..17efc28a6a 100644 --- a/indra/newview/llappearancemgr.cpp +++ b/indra/newview/llappearancemgr.cpp @@ -2590,7 +2590,7 @@ void LLAppearanceMgr::dumpItemArray(const LLInventoryModel::item_array_t& items, { asset_id = linked_item->getAssetUUID(); } - llinfos << msg << " " << i <<" " << item->getName() << " " << asset_id.asString() << llendl; + llinfos << msg << " " << i <<" " << (item ? item->getName() : "(nullitem)") << " " << asset_id.asString() << llendl; } llinfos << llendl; } diff --git a/indra/newview/llfloatervoiceeffect.cpp b/indra/newview/llfloatervoiceeffect.cpp index 3ab061dbea..61fe50e301 100644 --- a/indra/newview/llfloatervoiceeffect.cpp +++ b/indra/newview/llfloatervoiceeffect.cpp @@ -199,7 +199,7 @@ void LLFloaterVoiceEffect::refreshEffectList() if(sl_item) { LLFontGL::StyleFlags style = is_template_only ? LLFontGL::NORMAL : LLFontGL::BOLD; - LLScrollListText slt = dynamic_cast(sl_item->getColumn(0)); + LLScrollListText* slt = dynamic_cast(sl_item->getColumn(0)); llassert(slt); if (slt) { -- cgit v1.2.3 From 86da02f7d2f39705320dfea5c0f1b528ade7cad7 Mon Sep 17 00:00:00 2001 From: gabriel Date: Mon, 5 Jul 2010 16:29:30 +0100 Subject: =EXT-4655 fixed --- indra/newview/llfloaterscriptlimits.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llfloaterscriptlimits.cpp b/indra/newview/llfloaterscriptlimits.cpp index 4792d761d8..0a5499b166 100644 --- a/indra/newview/llfloaterscriptlimits.cpp +++ b/indra/newview/llfloaterscriptlimits.cpp @@ -557,8 +557,6 @@ BOOL LLPanelScriptLimitsRegionMemory::getLandScriptResources() void LLPanelScriptLimitsRegionMemory::processParcelInfo(const LLParcelData& parcel_data) { - mParcelId = parcel_data.parcel_id; - if(!getLandScriptResources()) { std::string msg_error = LLTrans::getString("ScriptLimitsRequestError"); @@ -580,6 +578,7 @@ void LLPanelScriptLimitsRegionMemory::setParcelID(const LLUUID& parcel_id) LLRemoteParcelInfoProcessor::getInstance()->removeObserver(mParcelId, this); mParcelId.setNull(); } + mParcelId = parcel_id; LLRemoteParcelInfoProcessor::getInstance()->addObserver(parcel_id, this); LLRemoteParcelInfoProcessor::getInstance()->sendParcelInfoRequest(parcel_id); } -- cgit v1.2.3 From 99e7e725072c8682f2de2eeb13d93181357d6a03 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Tue, 6 Jul 2010 11:20:05 +0100 Subject: CID-486 Checker: NULL_RETURNS Function: LLAgentWearables::revertWearable(LLWearableType::EType, unsigned int) File: /indra/newview/llagentwearables.cpp --- indra/newview/llagentwearables.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'indra/newview') diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp index e70511ce6e..6acbc16018 100644 --- a/indra/newview/llagentwearables.cpp +++ b/indra/newview/llagentwearables.cpp @@ -511,7 +511,11 @@ void LLAgentWearables::saveWearableAs(const LLWearableType::EType type, void LLAgentWearables::revertWearable(const LLWearableType::EType type, const U32 index) { LLWearable* wearable = getWearable(type, index); - wearable->revertValues(); + llassert(wearable); + if (wearable) + { + wearable->revertValues(); + } gAgent.sendAgentSetAppearance(); } -- cgit v1.2.3 From e04df15bf1280d29f998a18bbb326f4bfa991f69 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Tue, 6 Jul 2010 11:21:45 +0100 Subject: CID-484 Checker: NULL_RETURNS Function: LLAgentWearables::animateAllWearableParams(float, int) File: /indra/newview/llagentwearables.cpp --- indra/newview/llagentwearables.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'indra/newview') diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp index 6acbc16018..266aaaff4a 100644 --- a/indra/newview/llagentwearables.cpp +++ b/indra/newview/llagentwearables.cpp @@ -1944,7 +1944,11 @@ void LLAgentWearables::animateAllWearableParams(F32 delta, BOOL upload_bake) for (S32 count = 0; count < (S32)getWearableCount((LLWearableType::EType)type); ++count) { LLWearable *wearable = getWearable((LLWearableType::EType)type,count); - wearable->animateParams(delta, upload_bake); + llassert(wearable); + if (wearable) + { + wearable->animateParams(delta, upload_bake); + } } } } -- cgit v1.2.3 From a1bbba2be64daf332bdf511129b1ec4f2bea1540 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Tue, 6 Jul 2010 11:23:22 +0100 Subject: CID-485 Checker: NULL_RETURNS Function: LLAgentWearables::setWearableName(const LLUUID &, const std::basic_string, std::allocator>&) File: /indra/newview/llagentwearables.cpp --- indra/newview/llagentwearables.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview') diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp index 266aaaff4a..efa5eca217 100644 --- a/indra/newview/llagentwearables.cpp +++ b/indra/newview/llagentwearables.cpp @@ -547,6 +547,7 @@ void LLAgentWearables::setWearableName(const LLUUID& item_id, const std::string& { LLWearable* old_wearable = getWearable((LLWearableType::EType)i,j); llassert(old_wearable); + if (!old_wearable) continue; std::string old_name = old_wearable->getName(); old_wearable->setName(new_name); -- cgit v1.2.3