Changeset 225647 in webkit


Ignore:
Timestamp:
Dec 7, 2017 3:25:04 PM (6 years ago)
Author:
rniwa@webkit.org
Message:

iOS: Many AMP pages crash inside Document::updateStyleIfNeeded
https://bugs.webkit.org/show_bug.cgi?id=180550
<rdar://problem/35410390>

Reviewed by Zalan Bujtas.

The crash was caused when updatign the layout of an non-flattened frame inside a flattened frame.
In those cases, isInChildFrameWithFrameFlattening is false on the inner frame.

No new tests for now.

  • dom/NoEventDispatchAssertion.h:
  • rendering/RenderFrameBase.cpp:

(WebCore::RenderFrameBase::performLayoutWithFlattening): Disable the assertion temporarily here.
In theory, we should be able to remove the check for isInChildFrameWithFrameFlattening but we err
on the safer side for now.

Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r225645 r225647  
     12017-12-07  Ryosuke Niwa  <rniwa@webkit.org>
     2
     3        iOS: Many AMP pages crash inside Document::updateStyleIfNeeded
     4        https://bugs.webkit.org/show_bug.cgi?id=180550
     5        <rdar://problem/35410390>
     6
     7        Reviewed by Zalan Bujtas.
     8
     9        The crash was caused when updatign the layout of an non-flattened frame inside a flattened frame.
     10        In those cases, isInChildFrameWithFrameFlattening is false on the inner frame.
     11
     12        No new tests for now.
     13
     14        * dom/NoEventDispatchAssertion.h:
     15        * rendering/RenderFrameBase.cpp:
     16        (WebCore::RenderFrameBase::performLayoutWithFlattening): Disable the assertion temporarily here.
     17        In theory, we should be able to remove the check for isInChildFrameWithFrameFlattening but we err
     18        on the safer side for now.
     19
    1202017-12-07  Alex Christensen  <achristensen@webkit.org>
    221
  • trunk/Source/WebCore/dom/NoEventDispatchAssertion.h

    r224534 r225647  
    130130#endif
    131131
    132     // FIXME: Remove this class once the sync layout inside SVGImage::draw is removed.
     132    // FIXME: Remove this class once the sync layout inside SVGImage::draw is removed
     133    // and refactored the code in RenderFrameBase::performLayoutWithFlattening.
    133134    class DisableAssertionsInScope {
    134135    public:
  • trunk/Source/WebCore/rendering/RenderFrameBase.cpp

    r224537 r225647  
    3030#include "FrameView.h"
    3131#include "HTMLFrameElementBase.h"
     32#include "NoEventDispatchAssertion.h"
    3233#include "RenderView.h"
    3334#include <wtf/IsoMallocInlines.h>
     
    7475void RenderFrameBase::performLayoutWithFlattening(bool hasFixedWidth, bool hasFixedHeight)
    7576{
     77    // FIXME: Refactor frame flattening code so that we don't need to disable assertions here.
     78    NoEventDispatchAssertion::DisableAssertionsInScope scope;
    7679    if (!childRenderView())
    7780        return;
Note: See TracChangeset for help on using the changeset viewer.