Index: content/child/indexed_db/indexed_db_dispatcher.cc |
diff --git a/content/child/indexed_db/indexed_db_dispatcher.cc b/content/child/indexed_db/indexed_db_dispatcher.cc |
index edd64cf252b8153b1b48ff5cc6d17c92a0f47b8e..b6e57ea07d12d5b27e55825dfef2514543cd715f 100644 |
--- a/content/child/indexed_db/indexed_db_dispatcher.cc |
+++ b/content/child/indexed_db/indexed_db_dispatcher.cc |
@@ -643,7 +643,10 @@ void IndexedDBDispatcher::OnError(int32 ipc_thread_id, |
WebIDBCallbacks* callbacks = pending_callbacks_.Lookup(ipc_callbacks_id); |
if (!callbacks) |
return; |
- callbacks->onError(WebIDBDatabaseError(code, message)); |
+ if (message.empty()) |
+ callbacks->onError(WebIDBDatabaseError(code)); |
+ else |
+ callbacks->onError(WebIDBDatabaseError(code, message)); |
pending_callbacks_.Remove(ipc_callbacks_id); |
} |
@@ -657,7 +660,10 @@ void IndexedDBDispatcher::OnAbort(int32 ipc_thread_id, |
pending_database_callbacks_.Lookup(ipc_database_callbacks_id); |
if (!callbacks) |
return; |
- callbacks->onAbort(transaction_id, WebIDBDatabaseError(code, message)); |
+ if (message.empty()) |
+ callbacks->onAbort(transaction_id, WebIDBDatabaseError(code)); |
+ else |
+ callbacks->onAbort(transaction_id, WebIDBDatabaseError(code, message)); |
} |
void IndexedDBDispatcher::OnComplete(int32 ipc_thread_id, |