Skip to content
Snippets Groups Projects
Commit d06e1650 authored by Daniel Holbert's avatar Daniel Holbert
Browse files

Bug 1890514: Null-check 'view' before using it, in...

Bug 1890514: Null-check 'view' before using it, in nsTreeBodyFrame::RemoveImageCacheEntry.  a=dmeehan

If it's null, we'll now just take the existing something-failed early-return codepath.

The 'view' local variable here is really just an alias for mView, and we have
null-checks for mView elsewhere, so it's conceivable that it could be null when
we get to this point. (And we have a low but nonzero level of crash volume for
folks hitting a null-deref on this line, which seems to confirm that it is
occasionally null here.)

I'm not including a test since I'm not sure how to trigger the conditions
required to crash in this way.  But the change is pretty trivial and clearly
a step in the direction of safety-against-crashing.

Original Revision: https://phabricator.services.mozilla.com/D207817

Differential Revision: https://phabricator.services.mozilla.com/D208379
parent 3b76355e
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment