| 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 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 // If we get here with an empty m_transactionError, then the backend | 167 // If we get here with an empty m_transactionError, then the backend |
| 168 // must be waiting in the idle state waiting for this state to finish. | 168 // must be waiting in the idle state waiting for this state to finish. |
| 169 // Hence, it's thread safe to fetch the backend transactionError without | 169 // Hence, it's thread safe to fetch the backend transactionError without |
| 170 // a lock. | 170 // a lock. |
| 171 if (!m_transactionError) | 171 if (!m_transactionError) |
| 172 m_transactionError = m_backend->transactionError(); | 172 m_transactionError = m_backend->transactionError(); |
| 173 | 173 |
| 174 ASSERT(m_transactionError); | 174 ASSERT(m_transactionError); |
| 175 errorCallback->handleEvent(m_transactionError.get()); | 175 errorCallback->handleEvent(m_transactionError.get()); |
| 176 | 176 |
| 177 m_transactionError = 0; | 177 m_transactionError = nullptr; |
| 178 } | 178 } |
| 179 | 179 |
| 180 clearCallbackWrappers(); | 180 clearCallbackWrappers(); |
| 181 | 181 |
| 182 // Spec 4.3.2.10: Rollback the transaction. | 182 // Spec 4.3.2.10: Rollback the transaction. |
| 183 return SQLTransactionState::CleanupAfterTransactionErrorCallback; | 183 return SQLTransactionState::CleanupAfterTransactionErrorCallback; |
| 184 } | 184 } |
| 185 | 185 |
| 186 SQLTransactionState SQLTransaction::deliverStatementCallback() | 186 SQLTransactionState SQLTransaction::deliverStatementCallback() |
| 187 { | 187 { |
| (...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 303 m_successCallbackWrapper.clear(); | 303 m_successCallbackWrapper.clear(); |
| 304 m_errorCallbackWrapper.clear(); | 304 m_errorCallbackWrapper.clear(); |
| 305 } | 305 } |
| 306 | 306 |
| 307 PassOwnPtr<SQLTransactionErrorCallback> SQLTransaction::releaseErrorCallback() | 307 PassOwnPtr<SQLTransactionErrorCallback> SQLTransaction::releaseErrorCallback() |
| 308 { | 308 { |
| 309 return m_errorCallbackWrapper.unwrap(); | 309 return m_errorCallbackWrapper.unwrap(); |
| 310 } | 310 } |
| 311 | 311 |
| 312 } // namespace WebCore | 312 } // namespace WebCore |
| OLD | NEW |