Bug 48284 - Valgrind failure in GraphicsContext3DInternal::reshape
Summary: Valgrind failure in GraphicsContext3DInternal::reshape
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGL (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Kenneth Russell
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-10-25 18:34 PDT by Kenneth Russell
Modified: 2010-10-26 10:28 PDT (History)
4 users (show)

See Also:


Attachments
Patch (1.21 KB, patch)
2010-10-25 18:35 PDT, Kenneth Russell
kling: review+
kbr: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kenneth Russell 2010-10-25 18:34:18 PDT
There is a Valgrind failure reported in GraphicsContext3DInternal::reshape caused by uninitialized members m_cachedWidth and m_cachedHeight in WebGraphicsContext3DDefaultImpl. The stack trace:

14:19:56 memcheck_analyze.py [ERROR] FAIL! There were 1 errors: 
14:19:56 memcheck_analyze.py [ERROR] Command: /b/slave/webkit-rel-linux-valgrind-layout/build/src/sconsbuild/Release/test_shell --pixel-tests=/b/slave/webkit-rel-linux-valgrind-layout/build/src/webkit/Release/layout-test-results/png_result1.png --layout-tests
UninitCondition
Conditional jump or move depends on uninitialised value(s)
  WebCore::GraphicsContext3DInternal::reshape(int, int) (third_party/WebKit/WebKit/chromium/src/GraphicsContext3DChromium.cpp:229)
  WebCore::GraphicsContext3D::reshape(int, int) (third_party/WebKit/WebKit/chromium/src/GraphicsContext3DChromium.cpp:841)
  WebCore::WebGLRenderingContext::WebGLRenderingContext(WebCore::HTMLCanvasElement*, WTF::PassRefPtr<WebCore::GraphicsContext3D>) (third_party/WebKit/WebCore/html/canvas/WebGLRenderingContext.cpp:139)
  WebCore::WebGLRenderingContext::create(WebCore::HTMLCanvasElement*, WebCore::WebGLContextAttributes*) (third_party/WebKit/WebCore/html/canvas/WebGLRenderingContext.cpp:96)
  WebCore::HTMLCanvasElement::getContext(WTF::String const&, WebCore::CanvasContextAttributes*) (third_party/WebKit/WebCore/html/HTMLCanvasElement.cpp:173)
  WebCore::V8HTMLCanvasElement::getContextCallback(v8::Arguments const&) (third_party/WebKit/WebCore/bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:82)
  v8::internal::Object* v8::internal::HandleApiCallHelper<false>(v8::internal::(anonymous namespace)::BuiltinArguments<(v8::internal::BuiltinExtraArguments)1>) (v8/src/builtins.cc:983)
  0x5C6422D ()
  0x5C7C271 ()
  0x5C6609E ()
  0x5C7B4C9 ()
  0x5C75058 ()
  0x5C65421 ()
  v8::internal::Invoke(bool, v8::internal::Handle<v8::internal::JSFunction>, v8::internal::Handle<v8::internal::Object>, int, v8::internal::Object***, bool*) (v8/src/execution.cc:94)
  0x4E8E83B ()
Comment 1 Kenneth Russell 2010-10-25 18:35:39 PDT
Created attachment 71828 [details]
Patch
Comment 2 Andreas Kling 2010-10-26 04:13:22 PDT
Comment on attachment 71828 [details]
Patch

LGTM.
Comment 3 Kenneth Russell 2010-10-26 10:28:38 PDT
Committed r70534: <http://trac.webkit.org/changeset/70534>