Summary: | Platforms without USE(REQUEST_ANIMATION_FRAME_DISPLAY_MONITOR) don't need to query the page's displayID | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | James Robinson <jamesr> | ||||
Component: | New Bugs | Assignee: | James Robinson <jamesr> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | cmarrin, simon.fraser | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Attachments: |
|
Description
James Robinson
2012-03-14 20:29:30 PDT
Created attachment 131980 [details]
Patch
In r97405 Chris Marrin added a PlatformDisplayID parameter to ScriptedAnimationController::create(). This is only used if USE(REQUEST_ANIMATION_FRAME_DISPLAY_MONITOR) is set, which is only set on mac and blackberry (?). Unfortunately this code tries to grab the display ID from Document::page() whenever a callback is set, bug that's not correct - the page() on a Document might be NULL. We have crash reports in chromium from this exact situation. Having the display ID on a Document-owned object seems inherently a bit broken - Documents aren't always associated with a Page and can move between Pages. I had a patch series underway in https://bugs.webkit.org/show_bug.cgi?id=74165 to move the controller up to the Page, which I think will make it clearer how to deal with issues like this. I haven't had time to get around to this, but this patch avoids doing the unnecessary call (and resulting crash) on most platforms. Comment on attachment 131980 [details]
Patch
Can you please file a separate bug on page() possibly being null?
Committed r110821: <http://trac.webkit.org/changeset/110821> |