Fix NPE in dumpsys window
This crashes with an Android TV without sensor (i.e. TV) Change-Id: I5e461c6344811686f58860d427598626efdf0184
This commit is contained in:
@@ -193,7 +193,9 @@ public abstract class WindowOrientationListener {
|
||||
pw.println(prefix + "mSensor=" + mSensor);
|
||||
pw.println(prefix + "mRate=" + mRate);
|
||||
|
||||
mSensorEventListener.dumpLocked(pw, prefix);
|
||||
if (mSensorEventListener != null) {
|
||||
mSensorEventListener.dumpLocked(pw, prefix);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user