mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 979812 - Check the PlanarYCbCrImage data is valid. r=rillian
This commit is contained in:
parent
8b12dfab8f
commit
e4210a18a6
@ -290,6 +290,10 @@ nsresult VP8TrackEncoder::PrepareRawFrame(VideoChunk &aChunk)
|
||||
// Big-time assumption here that this is all contiguous data coming
|
||||
// from getUserMedia or other sources.
|
||||
MOZ_ASSERT(yuv);
|
||||
if (!yuv->IsValid()) {
|
||||
NS_WARNING("PlanarYCbCrImage is not valid");
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
const PlanarYCbCrImage::Data *data = yuv->GetData();
|
||||
|
||||
if (isYUV420(data) && !data->mCbSkip) { // 420 planar
|
||||
|
Loading…
Reference in New Issue
Block a user