OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008, 2013 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008, 2013 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
212 } | 212 } |
213 | 213 |
214 return tableNames; | 214 return tableNames; |
215 } | 215 } |
216 | 216 |
217 Vector<String> Database::tableNames() | 217 Vector<String> Database::tableNames() |
218 { | 218 { |
219 // FIXME: Not using isolatedCopy on these strings looks ok since threads tak
e strict turns | 219 // FIXME: Not using isolatedCopy on these strings looks ok since threads tak
e strict turns |
220 // in dealing with them. However, if the code changes, this may not be true
anymore. | 220 // in dealing with them. However, if the code changes, this may not be true
anymore. |
221 Vector<String> result; | 221 Vector<String> result; |
222 TaskSynchronizer synchronizer; | 222 DatabaseTaskSynchronizer synchronizer; |
223 if (!databaseContext()->databaseThread() || databaseContext()->databaseThrea
d()->terminationRequested(&synchronizer)) | 223 if (!databaseContext()->databaseThread() || databaseContext()->databaseThrea
d()->terminationRequested(&synchronizer)) |
224 return result; | 224 return result; |
225 | 225 |
226 OwnPtr<DatabaseTableNamesTask> task = DatabaseTableNamesTask::create(this, &
synchronizer, result); | 226 OwnPtr<DatabaseTableNamesTask> task = DatabaseTableNamesTask::create(this, &
synchronizer, result); |
227 databaseContext()->databaseThread()->scheduleTask(task.release()); | 227 databaseContext()->databaseThread()->scheduleTask(task.release()); |
228 synchronizer.waitForTaskCompletion(); | 228 synchronizer.waitForTaskCompletion(); |
229 | 229 |
230 return result; | 230 return result; |
231 } | 231 } |
232 | 232 |
(...skipping 11 matching lines...) Expand all Loading... |
244 backend()->reportStartTransactionResult(errorSite, webSqlErrorCode, sqliteEr
rorCode); | 244 backend()->reportStartTransactionResult(errorSite, webSqlErrorCode, sqliteEr
rorCode); |
245 } | 245 } |
246 | 246 |
247 void Database::reportCommitTransactionResult(int errorSite, int webSqlErrorCode,
int sqliteErrorCode) | 247 void Database::reportCommitTransactionResult(int errorSite, int webSqlErrorCode,
int sqliteErrorCode) |
248 { | 248 { |
249 backend()->reportCommitTransactionResult(errorSite, webSqlErrorCode, sqliteE
rrorCode); | 249 backend()->reportCommitTransactionResult(errorSite, webSqlErrorCode, sqliteE
rrorCode); |
250 } | 250 } |
251 | 251 |
252 | 252 |
253 } // namespace WebCore | 253 } // namespace WebCore |
OLD | NEW |