From 1fcc26d570435817b0ce8c84dbec590b960298be Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Wed, 10 Feb 2010 18:35:29 +0000 Subject: CID-141 Checker: NULL_RETURNS Function: LLFolderBridge::folderOptionsMenu() File: /indra/newview/llinventorybridge.cpp --- indra/newview/llinventorybridge.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index 749e1ce3f3..da95eaefca 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -2506,11 +2506,13 @@ void LLFolderBridge::folderOptionsMenu() if(!model) return; const LLInventoryCategory* category = model->getCategory(mUUID); + if(!category) return; + LLFolderType::EType type = category->getPreferredType(); - const bool is_system_folder = category && LLFolderType::lookupIsProtectedType(type); + const bool is_system_folder = LLFolderType::lookupIsProtectedType(type); // BAP change once we're no longer treating regular categories as ensembles. - const bool is_ensemble = category && (type == LLFolderType::FT_NONE || - LLFolderType::lookupIsEnsembleType(type)); + const bool is_ensemble = (type == LLFolderType::FT_NONE || + LLFolderType::lookupIsEnsembleType(type)); // calling card related functionality for folders. -- cgit v1.2.3