Maybe fix issue #3358322: Status and nav bar died while watching youtube
Or at least make it better. Now if we get a failure locking the surface,
we mark to do a full relayout pass later to try to get a new good surface.
Also fix some bugs in how activity manager was classifying processes for
their OOM adjustment to make better choices in what to kill.
Change-Id: I8e4aa86744211ba7693f9828291d8bbf2698274f
diff --git a/core/java/android/view/ViewRoot.java b/core/java/android/view/ViewRoot.java
index 41fc6c6..af19ab8 100644
--- a/core/java/android/view/ViewRoot.java
+++ b/core/java/android/view/ViewRoot.java
@@ -1550,11 +1550,13 @@
Log.e(TAG, "OutOfResourcesException locking surface", e);
// TODO: we should ask the window manager to do something!
// for now we just do nothing
+ mLayoutRequested = true; // ask wm for a new surface next time.
return;
} catch (IllegalArgumentException e) {
Log.e(TAG, "IllegalArgumentException locking surface", e);
// TODO: we should ask the window manager to do something!
// for now we just do nothing
+ mLayoutRequested = true; // ask wm for a new surface next time.
return;
}