am c02034a1: am 34c08828: Merge "Fix NPE in AR hardware binding sequence. b/22772433" into mnc-dr-dev
* commit 'c02034a131082080f7dee50c040ee037f6350be2': Fix NPE in AR hardware binding sequence. b/22772433
This commit is contained in:
@@ -123,6 +123,12 @@ public class ActivityRecognitionProxy {
|
|||||||
Log.e(TAG, "No watcher found on connection.");
|
Log.e(TAG, "No watcher found on connection.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (mInstance == null) {
|
||||||
|
// to keep backwards compatibility do not update the watcher when there is no
|
||||||
|
// instance available, or it will cause an NPE
|
||||||
|
Log.d(TAG, "AR HW instance not available, binding will be a no-op.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
try {
|
try {
|
||||||
watcher.onInstanceChanged(mInstance);
|
watcher.onInstanceChanged(mInstance);
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
|
|||||||
Reference in New Issue
Block a user