mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-16 05:45:33 +00:00
Bug 1748438 - Check for null surface in ImageBitmapRenderingContext::GetImageBuffer. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D135253
This commit is contained in:
parent
6cee5dbd76
commit
4d3a112bae
@ -138,6 +138,9 @@ mozilla::UniquePtr<uint8_t[]> ImageBitmapRenderingContext::GetImageBuffer(
|
||||
}
|
||||
|
||||
RefPtr<gfx::SourceSurface> surface = mImage->GetAsSourceSurface();
|
||||
if (!surface) {
|
||||
return nullptr;
|
||||
}
|
||||
RefPtr<gfx::DataSourceSurface> data = surface->GetDataSurface();
|
||||
if (!data) {
|
||||
return nullptr;
|
||||
|
Loading…
x
Reference in New Issue
Block a user