Log to EventLog on prepareUserStorage failure

Bug: 224585613
Change-Id: Id6dfb4f4c48d5cf4e71f54bdb6d0d6eea527caf5
Merged-In: Id6dfb4f4c48d5cf4e71f54bdb6d0d6eea527caf5
This commit is contained in:
Eric Biggers
2022-03-26 01:08:07 +00:00
parent e667b60402
commit 7d4ab9b698

View File

@@ -128,6 +128,7 @@ import android.util.ArrayMap;
import android.util.ArraySet; import android.util.ArraySet;
import android.util.AtomicFile; import android.util.AtomicFile;
import android.util.DataUnit; import android.util.DataUnit;
import android.util.EventLog;
import android.util.Log; import android.util.Log;
import android.util.Pair; import android.util.Pair;
import android.util.Slog; import android.util.Slog;
@@ -3398,6 +3399,7 @@ class StorageManagerService extends IStorageManager.Stub
} }
} }
} catch (Exception e) { } catch (Exception e) {
EventLog.writeEvent(0x534e4554, "224585613", -1, "");
Slog.wtf(TAG, e); Slog.wtf(TAG, e);
// Make sure to re-throw this exception; we must not ignore failure // Make sure to re-throw this exception; we must not ignore failure
// to prepare the user storage as it could indicate that encryption // to prepare the user storage as it could indicate that encryption