[webkit-reviews] review granted: [Bug 105572] IndexedDB: Use non-const buffers in put() to avoid copies : [Attachment 181043] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jan 2 12:12:31 PST 2013


Adam Barth <abarth at webkit.org> has granted Alec Flett
<alecflett at chromium.org>'s request for review:
Bug 105572: IndexedDB: Use non-const buffers in put() to avoid copies
https://bugs.webkit.org/show_bug.cgi?id=105572

Attachment 181043: Patch
https://bugs.webkit.org/attachment.cgi?id=181043&action=review

------- Additional Comments from Adam Barth <abarth at webkit.org>
View in context: https://bugs.webkit.org/attachment.cgi?id=181043&action=review


> Source/WebKit/chromium/src/WebIDBDatabaseImpl.cpp:169
> +    Vector<uint8_t> valueBuffer(value->size());
> +    valueBuffer.append(value->data(), value->size());
> +    m_databaseBackend->put(transactionId, objectStoreId, &valueBuffer, key,
static_cast<IDBDatabaseBackendInterface::PutMode>(putMode),
IDBCallbacksProxy::create(adoptPtr(callbacks)), indexIds, indexKeys);

OK.  Obviously the backend can't hold on to it for too long given that it's
allocated on the stack here.


More information about the webkit-reviews mailing list