Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix InvalidateSubFramebuffer error handling
The WebGL2 InvalidateSubFramebuffer function should generate
INVALID_VALUE when width or height is negative.
  • Loading branch information
mmatyas committed Apr 22, 2020
1 parent e69adfd commit a90f034
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
2 changes: 1 addition & 1 deletion components/script/dom/webgl2renderingcontext.rs
Expand Up @@ -3966,7 +3966,7 @@ impl WebGL2RenderingContextMethods for WebGL2RenderingContext {
}

if width < 0 || height < 0 {
return;
return self.base.webgl_error(InvalidValue);
}

self.base
Expand Down
Expand Up @@ -6,6 +6,3 @@
[WebGL test #17: successfullyParsed should be true (of type boolean). Was undefined (of type undefined).]
expected: FAIL

[WebGL test #11: getError expected: INVALID_VALUE. Was NO_ERROR : calling invalidateSubFramebuffer should generate INVALID_VALUE if width < 0 or height < 0.]
expected: FAIL

0 comments on commit a90f034

Please sign in to comment.