Index: content/browser/indexed_db/indexed_db_callbacks.cc |
diff --git a/content/browser/indexed_db/indexed_db_callbacks.cc b/content/browser/indexed_db/indexed_db_callbacks.cc |
index 6c541b7d5d88d0ba2a54d5441037ef561c101f3e..f0be17a4b0b4e5d79b78a03db81b92f10b659653 100644 |
--- a/content/browser/indexed_db/indexed_db_callbacks.cc |
+++ b/content/browser/indexed_db/indexed_db_callbacks.cc |
@@ -161,8 +161,11 @@ void IndexedDBCallbacks::OnUpgradeNeeded( |
DCHECK_NE(kNoDatabaseCallbacks, ipc_database_callbacks_id_); |
dispatcher_host_->RegisterTransactionId(host_transaction_id_, origin_); |
+ IndexedDBConnection* connection_ptr = connection.get(); |
int32_t ipc_database_id = |
dispatcher_host_->Add(connection.release(), ipc_thread_id_, origin_); |
+ connection_ptr->setId(ipc_database_id); |
+ |
if (ipc_database_id < 0) |
return; |
ipc_database_id_ = ipc_database_id; |
@@ -200,10 +203,11 @@ void IndexedDBCallbacks::OnSuccess( |
int32_t ipc_object_id = kNoDatabase; |
// Only register if the connection was not previously sent in OnUpgradeNeeded. |
if (ipc_database_id_ == kNoDatabase) { |
+ IndexedDBConnection* connection_ptr = connection.get(); |
ipc_object_id = |
dispatcher_host_->Add(connection.release(), ipc_thread_id_, origin_); |
+ connection_ptr->setId(ipc_object_id); |
cmumford
2016/07/07 21:14:21
IndexedDBDispatcherHost::Add() will delete connect
|
} |
- |
dispatcher_host_->Send(new IndexedDBMsg_CallbacksSuccessIDBDatabase( |
ipc_thread_id_, |
ipc_callbacks_id_, |