Bug 62348

Summary: IndexedDB: some string keys not properly stored and retrieved
Product: WebKit Reporter: Mark Pilgrim (Google) <pilgrim>
Component: New BugsAssignee: Joshua Bell <jsbell>
Status: RESOLVED FIXED    
Severity: Normal CC: dgrogan, hans, jsbell, tony, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
test case
none
Patch
none
Patch none

Description Mark Pilgrim (Google) 2011-06-08 20:07:57 PDT
Created attachment 96531 [details]
test case

Spun off from bug 62322, this test uses odd Unicode strings ("\u0000", "\ufffe", etc) as database names, objectstore names, record keys, and record values. It opens a database, creates an object store, adds a record, closes the database, then re-opens the database and opens a cursor to check the key and value that were previously added.

Most string keys work fine in this scenario, however 2 specific strings ("\u0000" and "\ufffe") are not stored properly as keys. (As values they are stored properly.)

Test case attached.
Comment 1 Joshua Bell 2011-10-14 13:05:19 PDT
Created attachment 111060 [details]
Patch
Comment 2 Joshua Bell 2011-10-14 13:06:53 PDT
Comment on attachment 111060 [details]
Patch

Mark's test case passes - this was presumably fixed when we moved to LevelDB.  We should add this to LayoutTests, which is all the patch does.
Comment 3 Tony Chang 2011-10-14 13:09:11 PDT
Comment on attachment 111060 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=111060&action=review

> LayoutTests/storage/indexeddb/odd-strings.html:1
> +

Nit: stray blank line
Comment 4 Joshua Bell 2011-10-14 13:11:51 PDT
Created attachment 111063 [details]
Patch
Comment 5 WebKit Review Bot 2011-10-15 00:18:22 PDT
Comment on attachment 111063 [details]
Patch

Clearing flags on attachment: 111063

Committed r97547: <http://trac.webkit.org/changeset/97547>
Comment 6 WebKit Review Bot 2011-10-15 00:18:27 PDT
All reviewed patches have been landed.  Closing bug.