⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 98389 in webkit


Ignore:
Timestamp:
Oct 25, 2011, 1:46:14 PM (15 years ago)
Author:
andersca@apple.com
Message:

REGRESSION(97821): HistoryController::itemsAreClones crashes a lot
https://bugs.webkit.org/show_bug.cgi?id=70827
<rdar://problem/10342925>

Reviewed by Adam Barth.

Check that m_currentItem is non-null before passing it to itemsAreClones. While I wasn't
able to make a test case that would reproduce this crash, we do check m_currentItem for null
everywhere else, and the crash log indicates that this would fix the crash.

  • loader/HistoryController.cpp:

(WebCore::HistoryController::recursiveUpdateForCommit):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r98388 r98389  
     12011-10-25  Anders Carlsson  <andersca@apple.com>
     2
     3        REGRESSION(97821): HistoryController::itemsAreClones crashes a lot
     4        https://bugs.webkit.org/show_bug.cgi?id=70827
     5        <rdar://problem/10342925>
     6
     7        Reviewed by Adam Barth.
     8
     9        Check that m_currentItem is non-null before passing it to itemsAreClones. While I wasn't
     10        able to make a test case that would reproduce this crash, we do check m_currentItem for null
     11        everywhere else, and the crash log indicates that this would fix the crash.
     12
     13        * loader/HistoryController.cpp:
     14        (WebCore::HistoryController::recursiveUpdateForCommit):
     15
    1162011-10-25  Adam Barth  <abarth@webkit.org>
    217
  • trunk/Source/WebCore/loader/HistoryController.cpp

    r97821 r98389  
    473473    // (a matching URL and frame tree snapshot), just restore the scroll position.
    474474    // Save form state (works from currentItem, since m_frameLoadComplete is true)
    475     if (itemsAreClones(m_currentItem.get(), m_provisionalItem.get())) {
     475    if (m_currentItem && itemsAreClones(m_currentItem.get(), m_provisionalItem.get())) {
    476476        ASSERT(m_frameLoadComplete);
    477477        saveDocumentState();
Note: See TracChangeset for help on using the changeset viewer.