Bug 106442 - IndexedDB: Remove ASSERTs that can't assert but result in compiler warnings
Summary: IndexedDB: Remove ASSERTs that can't assert but result in compiler warnings
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Jussi Kukkonen (jku)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-01-09 04:32 PST by Jussi Kukkonen (jku)
Modified: 2013-01-09 07:39 PST (History)
6 users (show)

See Also:


Attachments
Patch (1.85 KB, patch)
2013-01-09 04:40 PST, Jussi Kukkonen (jku)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jussi Kukkonen (jku) 2013-01-09 04:32:32 PST
IDBLevelDBCoding::m_metaDataType has been changed to unsigned so ASSERT(m_metaDataType >= 0) is not useful: it does create build problems at least with EFL.

Attaching patch.
Comment 1 Jussi Kukkonen (jku) 2013-01-09 04:40:39 PST
Created attachment 181896 [details]
Patch
Comment 2 Chris Dumez 2013-01-09 04:45:09 PST
How about this?

> ObjectStoreMetaDataKey::ObjectStoreMetaDataKey()
>     : m_objectStoreId(-1)
>     , m_metaDataType(-1)
> {
> }
Comment 3 Kentaro Hara 2013-01-09 04:57:28 PST
Comment on attachment 181896 [details]
Patch

OK
Comment 4 Jussi Kukkonen (jku) 2013-01-09 05:19:03 PST
(In reply to comment #2)
> How about this?
> 
> > ObjectStoreMetaDataKey::ObjectStoreMetaDataKey()
> >     : m_objectStoreId(-1)
> >     , m_metaDataType(-1)
> > {
> > }

Good that you mentioned, I was planning to but forgot.

It's ugly but should work, assuming that presents a metadatatype that does not exist: see "enum MetaDataType" in the header for the 'good' values of metadatatype. We could add a unsetObjectStoreMetaDataType but that shouldn't be part of this patch I guess.
Comment 5 Kentaro Hara 2013-01-09 06:59:06 PST
Comment on attachment 181896 [details]
Patch

Please fix the issue Christophe pointed out in a follow-up patch.
Comment 6 WebKit Review Bot 2013-01-09 07:39:36 PST
Comment on attachment 181896 [details]
Patch

Clearing flags on attachment: 181896

Committed r139193: <http://trac.webkit.org/changeset/139193>
Comment 7 WebKit Review Bot 2013-01-09 07:39:40 PST
All reviewed patches have been landed.  Closing bug.