Merge "Don't crash settings when out of space." into nyc-dev
This commit is contained in:
@@ -31,6 +31,7 @@ import android.database.DatabaseUtils;
|
||||
import android.database.MergeCursor;
|
||||
import android.database.sqlite.SQLiteDatabase;
|
||||
import android.database.sqlite.SQLiteException;
|
||||
import android.database.sqlite.SQLiteFullException;
|
||||
import android.net.Uri;
|
||||
import android.os.AsyncTask;
|
||||
import android.provider.SearchIndexableData;
|
||||
@@ -1194,6 +1195,7 @@ public class Index {
|
||||
|
||||
@Override
|
||||
protected Void doInBackground(UpdateData... params) {
|
||||
try {
|
||||
final List<SearchIndexableData> dataToUpdate = params[0].dataToUpdate;
|
||||
final List<SearchIndexableData> dataToDelete = params[0].dataToDelete;
|
||||
final Map<String, List<String>> nonIndexableKeys = params[0].nonIndexableKeys;
|
||||
@@ -1224,6 +1226,9 @@ public class Index {
|
||||
if (fullIndex) {
|
||||
IndexDatabaseHelper.setLocaleIndexed(mContext, localeStr);
|
||||
}
|
||||
} catch (SQLiteFullException e) {
|
||||
Log.e(LOG_TAG, "Unable to index search, out of space", e);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
Reference in New Issue
Block a user