Merge remote-tracking branch 'origin/master'

This commit is contained in:
Weblate 2016-09-15 15:55:26 +02:00
commit 3c2ae8c945

View file

@ -14,9 +14,8 @@ public class SQLiteAPIImpl implements SQLiteAPI {
@Override @Override
public SQLiteConnection getOrCreateDatabase(String name, boolean readOnly) { public SQLiteConnection getOrCreateDatabase(String name, boolean readOnly) {
android.database.sqlite.SQLiteDatabase db = SQLiteDatabase.openDatabase(app.getDatabasePath(name).getAbsolutePath(), null, android.database.sqlite.SQLiteDatabase db = app.openOrCreateDatabase(name,
(readOnly? SQLiteDatabase.OPEN_READONLY : (SQLiteDatabase.OPEN_READWRITE | SQLiteDatabase.ENABLE_WRITE_AHEAD_LOGGING)) readOnly ? SQLiteDatabase.OPEN_READONLY : (SQLiteDatabase.OPEN_READWRITE | SQLiteDatabase.ENABLE_WRITE_AHEAD_LOGGING), null);
| SQLiteDatabase.CREATE_IF_NECESSARY);
if(db == null) { if(db == null) {
return null; return null;
} }