DescriptionTentative fix of a crash in Oilpan GC after a database thread termination.
Make sure DatabaseThread::m_openDatabaseSet has no backing store
when a database thread is terminated.
m_openDatabaseSet outlives a database thread, and its backing store
is allocated in the database thread. So, we should unlink the
backing store before the thread termination.
* DatabaseThread::cleanupDatabaseThread
It's possible m_openDatabaseSet.size() is zero and
m_openDatabaseSet still has backing store in the following scenario:
1. A web page opens a database. m_openDatabaseSet has it.
2. Chromium calls DatabaseTracker::closeDatabasesImmediately()
3. It calls m_openDatabaseSet.remove().
* DatabaseThread::recordDatabaseOpen
Don't add a Database object after termination request.
I think this can't happen. But we change it just in case.
This CL has no tests. It's very hard to make an automated test for the
scenario.
BUG=423271
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=183730
Patch Set 1 : #
Total comments: 5
Messages
Total messages: 10 (4 generated)
|