Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f3cf8a4d authored by Vasu Nori's avatar Vasu Nori
Browse files

when corruption occurs, log a warning before closing db

and database.close() should NOT set mPath to null.

a few other minor changes included in this CL
1. if it is memory database, no need to delete any file
2. if 2 threads are sharing the same connection, and if corruption occurs
on it, one thread closes the db and deletes db - while the other
thread is still using it. this can cause SQLITE_MISUSE error.
to prevent this, every method in SQLiteDatabse should make sure
db is open before exec'ing sql statements. bug:2531172

Change-Id: I4cb5ab8539f46d7f8b26c3f830d799adf46444b6
parent 7e6ee513
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment