[Webkit-unassigned] [Bug 91456] New: IndexedDB: Key generator state not maintained across connections

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jul 16 17:45:24 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=91456

           Summary: IndexedDB: Key generator state not maintained across
                    connections
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Unspecified
        OS/Version: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebCore Misc.
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: jsbell at chromium.org
                CC: dgrogan at chromium.org, alecflett at chromium.org


Created an attachment (id=152658)
 --> (https://bugs.webkit.org/attachment.cgi?id=152658&action=review)
Repro case - should show different keys

The IDB spec http://dvcs.w3.org/hg/IndexedDB/raw-file/tip/Overview.html#key-generator-concept says:

"The current number for a key generator never decreases, other than as a result of database operations being reverted. Deleting a record from an object store never affects the object store's key generator. Even clearing all records from an object store, for example using the clear() function, does not affect the current number of the object store's key generator."

The WebKit implementation violates this in this case:

db.open(...);
store.put(value1);
store.clear();
db.close();
db.open();
store.put(value2);

The same key will be used for value2 as was used for value1. This is because the key generator state is not actually saved, but derived from the maximum key in the database at the time it is first needed.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list