Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1244)

Unified Diff: Source/modules/webdatabase/Database.cpp

Issue 210833005: Oilpan: Prepare to move SQLError to oilpan heap. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: apply comments Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/modules/webdatabase/ChangeVersionWrapper.cpp ('k') | Source/modules/webdatabase/SQLError.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/webdatabase/Database.cpp
diff --git a/Source/modules/webdatabase/Database.cpp b/Source/modules/webdatabase/Database.cpp
index 4471248fd2bf720d154a4a6836a2ce357355091f..b7ee49198548585433cb334285f6eb6fb1ceaa3b 100644
--- a/Source/modules/webdatabase/Database.cpp
+++ b/Source/modules/webdatabase/Database.cpp
@@ -129,8 +129,9 @@ void Database::readTransaction(PassOwnPtr<SQLTransactionCallback> callback, Pass
runTransaction(callback, errorCallback, successCallback, true);
}
-static void callTransactionErrorCallback(ExecutionContext*, PassOwnPtr<SQLTransactionErrorCallback> callback, PassRefPtr<SQLError> error)
+static void callTransactionErrorCallback(ExecutionContext*, PassOwnPtr<SQLTransactionErrorCallback> callback, PassOwnPtr<SQLErrorData> errorData)
{
+ RefPtrWillBeRawPtr<SQLError> error = SQLError::create(*errorData);
callback->handleEvent(error.get());
}
@@ -149,7 +150,7 @@ void Database::runTransaction(PassOwnPtr<SQLTransactionCallback> callback, PassO
OwnPtr<SQLTransactionErrorCallback> callback = transaction->releaseErrorCallback();
ASSERT(callback == originalErrorCallback);
if (callback) {
- RefPtr<SQLError> error = SQLError::create(SQLError::UNKNOWN_ERR, "database has been closed");
+ OwnPtr<SQLErrorData> error = SQLErrorData::create(SQLError::UNKNOWN_ERR, "database has been closed");
executionContext()->postTask(createCallbackTask(&callTransactionErrorCallback, callback.release(), error.release()));
}
}
« no previous file with comments | « Source/modules/webdatabase/ChangeVersionWrapper.cpp ('k') | Source/modules/webdatabase/SQLError.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698