Changeset 164381 in webkit


Ignore:
Timestamp:
Feb 19, 2014 12:44:45 PM (10 years ago)
Author:
timothy_horton@apple.com
Message:

[wk2] REGRESSION (r162710): Open tab urls not restored after switching to new Safari build
https://bugs.webkit.org/show_bug.cgi?id=128536
<rdar://problem/15911839>

Reviewed by Dan Bernstein.

  • UIProcess/cf/WebBackForwardListCF.cpp:

(WebKit::extractBackForwardListEntriesFromArray):
Don't fail to extract an entry if it doesn't have a snapshot UUID.

  • UIProcess/cf/WebPageProxyCF.cpp:

It turns out that this was the wrong version to bump, and we don't support
reading different versions of the session state data.

Location:
trunk/Source/WebKit2
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r164366 r164381  
     12014-02-19  Tim Horton  <timothy_horton@apple.com>
     2
     3        [wk2] REGRESSION (r162710): Open tab urls not restored after switching to new Safari build
     4        https://bugs.webkit.org/show_bug.cgi?id=128536
     5        <rdar://problem/15911839>
     6
     7        Reviewed by Dan Bernstein.
     8
     9        * UIProcess/cf/WebBackForwardListCF.cpp:
     10        (WebKit::extractBackForwardListEntriesFromArray):
     11        Don't fail to extract an entry if it doesn't have a snapshot UUID.
     12
     13        * UIProcess/cf/WebPageProxyCF.cpp:
     14        It turns out that this was the wrong version to bump, and we don't support
     15        reading different versions of the session state data.
     16
    1172014-02-19  Brady Eidson  <beidson@apple.com>
    218
  • trunk/Source/WebKit2/UIProcess/cf/WebBackForwardListCF.cpp

    r162710 r164381  
    312312        }
    313313
    314         CFStringRef snapshotUUID = (CFStringRef)CFDictionaryGetValue(entryDictionary, sessionHistoryEntrySnapshotUUIDKey);
    315         if (!snapshotUUID || CFGetTypeID(snapshotUUID) != CFStringGetTypeID()) {
    316             LOG(SessionState, "WebBackForwardList entry at index %i does not have a valid snapshot UUID", (int)i);
    317             return false;
    318         }
    319 
    320314        CFDataRef backForwardData = (CFDataRef)CFDictionaryGetValue(entryDictionary, sessionHistoryEntryDataKey);
    321315        if (!backForwardData || CFGetTypeID(backForwardData) != CFDataGetTypeID()) {
     
    325319
    326320        auto item = WebBackForwardListItem::create(originalURL, entryURL, entryTitle, CFDataGetBytePtr(backForwardData), CFDataGetLength(backForwardData), generateWebBackForwardItemID());
    327         item->setSnapshotUUID(snapshotUUID);
     321
     322        CFStringRef snapshotUUID = (CFStringRef)CFDictionaryGetValue(entryDictionary, sessionHistoryEntrySnapshotUUIDKey);
     323        if (snapshotUUID && CFGetTypeID(snapshotUUID) == CFStringGetTypeID())
     324            item->setSnapshotUUID(snapshotUUID);
     325
    328326        entries.append(item);
    329327    }
  • trunk/Source/WebKit2/UIProcess/cf/WebPageProxyCF.cpp

    r163037 r164381  
    4545static CFStringRef provisionalURLKey = CFSTR("ProvisionalURL");
    4646
    47 static const UInt32 CurrentSessionStateDataVersion = 3;
     47static const UInt32 CurrentSessionStateDataVersion = 2;
    4848
    4949PassRefPtr<API::Data> WebPageProxy::sessionStateData(WebPageProxySessionStateFilterCallback filter, void* context) const
Note: See TracChangeset for help on using the changeset viewer.