Bug 675630 - Fix null dereference in media memory reporter. r=cpearce

This commit is contained in:
Matthew Gregan 2011-08-02 15:21:52 +12:00
parent 237262a45f
commit b760b58bf8

View File

@ -476,6 +476,9 @@ public:
virtual void* operator()(void* anObject) {
const VideoData* v = static_cast<const VideoData*>(anObject);
if (!v->mImage) {
return nsnull;
}
NS_ASSERTION(v->mImage->GetFormat() == mozilla::layers::Image::PLANAR_YCBCR,
"Wrong format?");
mozilla::layers::PlanarYCbCrImage* vi = static_cast<mozilla::layers::PlanarYCbCrImage*>(v->mImage.get());