[DO NOT MERGE] Check CellInfoCallback Detail for Null

In cases where the source of the CellInfo fails
but does not generate a Throwable, the detail info
will not be provided and should be null. Inside the
user process, we need to check for null before
dereferencing the detail object. Oops. :-(

Bug: 142706765
Bug: 142421696
Test: manual
Change-Id: I1307d1d7aacef0bbd33bfc73700ee774e12e64c1
This commit is contained in:
Nathan Harold
2019-10-15 11:28:00 -07:00
parent 5491eb92fc
commit fff052067c

View File

@@ -5435,7 +5435,8 @@ public class TelephonyManager {
public void onError(int errorCode, android.os.ParcelableException detail) {
Binder.withCleanCallingIdentity(() ->
executor.execute(() -> callback.onError(
errorCode, detail.getCause())));
errorCode,
detail == null ? null : detail.getCause())));
}
}, getOpPackageName());
@@ -5475,7 +5476,8 @@ public class TelephonyManager {
public void onError(int errorCode, android.os.ParcelableException detail) {
Binder.withCleanCallingIdentity(() ->
executor.execute(() -> callback.onError(
errorCode, detail.getCause())));
errorCode,
detail == null ? null : detail.getCause())));
}
}, getOpPackageName(), workSource);
} catch (RemoteException ex) {