1. simon_linden
  2. viewer-rabbit

Commits

Nicky  committed ac149d8

Crashfix; don't crash in LLRightClickInventoryFetchDescendentsObserver::execute when there's a 0 pointer for item_array or cat_array.

  • Participants
  • Parent commits 99e8f16
  • Branches default

Comments (0)

Files changed (1)

File indra/newview/llinventorybridge.cpp

View file
 		LLInventoryModel::item_array_t* item_array;
 		gInventory.getDirectDescendentsOf(*current_folder, cat_array, item_array);
 
-		S32 item_count = item_array->count();
-		S32 cat_count = cat_array->count();
-	
+		S32 item_count(0);
+		if( item_array )
+		{			
+			item_count = item_array->count();
+		}
+		
+		S32 cat_count(0);
+		if( cat_array )
+		{			
+			cat_count = cat_array->count();
+		}
+
 		// Move to next if current folder empty
 		if ((item_count == 0) && (cat_count == 0))
-	{
+		{
 			continue;
-	}
+		}
 
 		uuid_vec_t ids;
 		LLRightClickInventoryFetchObserver* outfit = NULL;