Changeset 228672 in webkit


Ignore:
Timestamp:
Feb 19, 2018 5:17:51 AM (6 years ago)
Author:
Carlos Garcia Campos
Message:

Merge r228299 - Form submission after navigation fails when decidePolicyForNavigationAction is async
https://bugs.webkit.org/show_bug.cgi?id=182412
<rdar://problem/35181099>

Reviewed by Alex Christensen.

Source/WebCore:

When the form is submitted and schedules the load in an iframe that is already loading,
FrameLoader::stopLoading() is called as expected. However, because policy checks can
now be asynchronous, stopLoading() also needs to stop pending policy checks. Otherwise,
continueLoadAfterNavigationPolicy() gets called for a cancelled load and we're in trouble
because the FrameLoader was reused for another load since then.

Test: http/tests/navigation/sync-form-submit-iframe.html

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::stopLoading):

LayoutTests:

Import layout test coverage from Alex's earlier patch.

  • http/tests/navigation/resources/a.html: Added.
  • http/tests/navigation/resources/b.html: Added.
  • http/tests/navigation/sync-form-submit-iframe-expected.txt: Added.
  • http/tests/navigation/sync-form-submit-iframe.html: Added.
Location:
releases/WebKitGTK/webkit-2.20
Files:
4 added
3 edited

Legend:

Unmodified
Added
Removed
  • releases/WebKitGTK/webkit-2.20/LayoutTests/ChangeLog

    r228666 r228672  
     12018-02-08  Chris Dumez  <cdumez@apple.com>
     2
     3        Form submission after navigation fails when decidePolicyForNavigationAction is async
     4        https://bugs.webkit.org/show_bug.cgi?id=182412
     5        <rdar://problem/35181099>
     6
     7        Reviewed by Alex Christensen.
     8
     9        Import layout test coverage from Alex's earlier patch.
     10
     11        * http/tests/navigation/resources/a.html: Added.
     12        * http/tests/navigation/resources/b.html: Added.
     13        * http/tests/navigation/sync-form-submit-iframe-expected.txt: Added.
     14        * http/tests/navigation/sync-form-submit-iframe.html: Added.
     15
    1162018-02-08  Chris Fleizach  <cfleizach@apple.com>
    217
  • releases/WebKitGTK/webkit-2.20/Source/WebCore/ChangeLog

    r228670 r228672  
     12018-02-08  Chris Dumez  <cdumez@apple.com>
     2
     3        Form submission after navigation fails when decidePolicyForNavigationAction is async
     4        https://bugs.webkit.org/show_bug.cgi?id=182412
     5        <rdar://problem/35181099>
     6
     7        Reviewed by Alex Christensen.
     8
     9        When the form is submitted and schedules the load in an iframe that is already loading,
     10        FrameLoader::stopLoading() is called as expected. However, because policy checks can
     11        now be asynchronous, stopLoading() also needs to stop pending policy checks. Otherwise,
     12        continueLoadAfterNavigationPolicy() gets called for a cancelled load and we're in trouble
     13        because the FrameLoader was reused for another load since then.
     14
     15        Test: http/tests/navigation/sync-form-submit-iframe.html
     16
     17        * loader/FrameLoader.cpp:
     18        (WebCore::FrameLoader::stopLoading):
     19
    1202018-02-08  Zalan Bujtas  <zalan@apple.com>
    221
  • releases/WebKitGTK/webkit-2.20/Source/WebCore/loader/FrameLoader.cpp

    r228045 r228672  
    488488    }
    489489
     490    policyChecker().stopCheck();
     491
    490492    // FIXME: This will cancel redirection timer, which really needs to be restarted when restoring the frame from b/f cache.
    491493    m_frame.navigationScheduler().cancel();
Note: See TracChangeset for help on using the changeset viewer.