Merge "camera2: Don't NPE when closing the CameraDevice" into klp-dev

This commit is contained in:
Igor Murashkin
2013-09-04 00:44:31 +00:00
committed by Android (Google) Code Review

View File

@@ -301,7 +301,9 @@ public class CameraDevice implements android.hardware.camera2.CameraDevice {
synchronized (mLock) {
try {
mRemoteDevice.disconnect();
if (mRemoteDevice != null) {
mRemoteDevice.disconnect();
}
} catch (CameraRuntimeException e) {
throw e.asChecked();
} catch (RemoteException e) {