Bug 58948 - [chromium] DrawingBuffer incorrectly initializes value before getBooleanv call
Summary: [chromium] DrawingBuffer incorrectly initializes value before getBooleanv call
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Adrienne Walker
Depends on:
Reported: 2011-04-19 17:27 PDT by Adrienne Walker
Modified: 2011-04-19 17:51 PDT (History)
4 users (show)

See Also:

Patch (1.56 KB, patch)
2011-04-19 17:31 PDT, Adrienne Walker
kbr: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Adrienne Walker 2011-04-19 17:27:24 PDT
DrawingBuffer::clearFramebuffer() initializes the depthMask to true before calling getBooleanv.  In the command buffer code (gpu/command_buffer/client/gles2_c_lib_autogen.h:315), we check that the destination for all get calls has been correctly initialized, which means that it's either been initialized to 0 or -1.  See the macro in gles2_c_lib.cc:33.  This should probably be initialized to false instead for consistency.

This asserts when loading http://www.masterofthewebgame.com on Linux (only platform tested) at ToT (chromium r82193, webkit r84319).

(See also: probably would have been caught if the command buffer was tested in DRT.)
Comment 1 Adrienne Walker 2011-04-19 17:31:43 PDT
Created attachment 90279 [details]
Comment 2 Stephen White 2011-04-19 17:38:04 PDT
Comment on attachment 90279 [details]

If a C++-style bool is the wrong type for this call, should this perhaps be 0 instead of false?

Otherwise, looks good to me (unofficially).
Comment 3 Kenneth Russell 2011-04-19 17:43:04 PDT
Comment on attachment 90279 [details]

Argh. Looks fine.
Comment 4 Adrienne Walker 2011-04-19 17:51:52 PDT
Committed r84323: <http://trac.webkit.org/changeset/84323>