Merge "Fix NPE in BootReceiver.addTombstoneToDropBox." am: f2ab01c09e am: 3615fbdf11
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1823178 Change-Id: Ic65d659d0cc2116d9289b2e6581af23917285dc2
This commit is contained in:
@@ -476,7 +476,11 @@ public class BootReceiver extends BroadcastReceiver {
|
|||||||
*/
|
*/
|
||||||
public static void addTombstoneToDropBox(Context ctx, File tombstone, boolean proto) {
|
public static void addTombstoneToDropBox(Context ctx, File tombstone, boolean proto) {
|
||||||
final DropBoxManager db = ctx.getSystemService(DropBoxManager.class);
|
final DropBoxManager db = ctx.getSystemService(DropBoxManager.class);
|
||||||
final String bootReason = SystemProperties.get("ro.boot.bootreason", null);
|
if (db == null) {
|
||||||
|
Slog.e(TAG, "Can't log tombstone: DropBoxManager not available");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
HashMap<String, Long> timestamps = readTimestamps();
|
HashMap<String, Long> timestamps = readTimestamps();
|
||||||
try {
|
try {
|
||||||
if (proto) {
|
if (proto) {
|
||||||
|
|||||||
Reference in New Issue
Block a user