Don't crash on OOM. b=353997 r+sr=darin
This commit is contained in:
@@ -211,6 +211,7 @@ nsCOMArrayEnumerator::operator new (size_t size, const nsCOMArray_base& aArray)
|
||||
// do the actual allocation
|
||||
nsCOMArrayEnumerator * result =
|
||||
NS_STATIC_CAST(nsCOMArrayEnumerator*, ::operator new(size));
|
||||
NS_ENSURE_TRUE(result, nsnull);
|
||||
|
||||
// now need to copy over the values, and addref each one
|
||||
// now this might seem like a lot of work, but we're actually just
|
||||
|
||||
Reference in New Issue
Block a user