mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 765198 - WebGL crash in readPixels with null destination - r=bz
This commit is contained in:
parent
03af05e76c
commit
5976d2e454
@ -3849,6 +3849,9 @@ WebGLContext::ReadPixels(WebGLint x, WebGLint y, WebGLsizei width,
|
|||||||
if (width < 0 || height < 0)
|
if (width < 0 || height < 0)
|
||||||
return ErrorInvalidValue("readPixels: negative size passed");
|
return ErrorInvalidValue("readPixels: negative size passed");
|
||||||
|
|
||||||
|
if (!pixels)
|
||||||
|
return ErrorInvalidValue("readPixels: null destination buffer");
|
||||||
|
|
||||||
const WebGLRectangleObject *framebufferRect = FramebufferRectangleObject();
|
const WebGLRectangleObject *framebufferRect = FramebufferRectangleObject();
|
||||||
WebGLsizei framebufferWidth = framebufferRect ? framebufferRect->Width() : 0;
|
WebGLsizei framebufferWidth = framebufferRect ? framebufferRect->Width() : 0;
|
||||||
WebGLsizei framebufferHeight = framebufferRect ? framebufferRect->Height() : 0;
|
WebGLsizei framebufferHeight = framebufferRect ? framebufferRect->Height() : 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user