Merge \"Handle invalid empty args to createAutoBrightnessSpline\" into nyc-mr1-dev
am: 136e649760
Change-Id: Ieb31555a395857b991a2131769bee3488ad2d1db
This commit is contained in:
@@ -1181,6 +1181,10 @@ final class DisplayPowerController implements AutomaticBrightnessController.Call
|
||||
}
|
||||
|
||||
private static Spline createAutoBrightnessSpline(int[] lux, int[] brightness) {
|
||||
if (lux == null || lux.length == 0 || brightness == null || brightness.length == 0) {
|
||||
Slog.e(TAG, "Could not create auto-brightness spline.");
|
||||
return null;
|
||||
}
|
||||
try {
|
||||
final int n = brightness.length;
|
||||
float[] x = new float[n];
|
||||
|
||||
Reference in New Issue
Block a user