Changeset 88925 in webkit


Ignore:
Timestamp:
Jun 15, 2011 6:57:09 AM (13 years ago)
Author:
hans@chromium.org
Message:

2011-06-14 Hans Wennborg <hans@chromium.org>

Reviewed by Tony Gentilcore.

IndexedDB: Use fileExists() first when checking if SQLite db exists
https://bugs.webkit.org/show_bug.cgi?id=62638

In IDBSQLiteBackingStore::backingStoreExists(), which is used to check
if a SQLite database exists and should be considered for migration,
check if the file exists first.

Trying to open a SQLite database for a non-existing file prints a
noisy error message in debug builds.

No new functionality, no new tests.

  • storage/IDBSQLiteBackingStore.cpp: (WebCore::IDBSQLiteBackingStore::backingStoreExists):
Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r88920 r88925  
     12011-06-14  Hans Wennborg  <hans@chromium.org>
     2
     3        Reviewed by Tony Gentilcore.
     4
     5        IndexedDB: Use fileExists() first when checking if SQLite db exists
     6        https://bugs.webkit.org/show_bug.cgi?id=62638
     7
     8        In IDBSQLiteBackingStore::backingStoreExists(), which is used to check
     9        if a SQLite database exists and should be considered for migration,
     10        check if the file exists first.
     11
     12        Trying to open a SQLite database for a non-existing file prints a
     13        noisy error message in debug builds.
     14
     15        No new functionality, no new tests.
     16
     17        * storage/IDBSQLiteBackingStore.cpp:
     18        (WebCore::IDBSQLiteBackingStore::backingStoreExists):
     19
    1202011-06-14  Alexander Pavlov  <apavlov@chromium.org>
    221
  • trunk/Source/WebCore/storage/IDBSQLiteBackingStore.cpp

    r88358 r88925  
    995995{
    996996    String path = pathByAppendingComponent(pathBase, securityOrigin->databaseIdentifier() + ".indexeddb");
     997    if (!fileExists(path))
     998        return false;
    997999
    9981000    SQLiteDatabase db;
Note: See TracChangeset for help on using the changeset viewer.