Fixed crash when openning broken camera

pull/213/head
alexander.melnikov 7 years ago
parent 86c3eae957
commit fcf878529c
  1. 3
      cameraview/src/main/java/com/otaliastudios/cameraview/Camera1.java

@ -269,7 +269,8 @@ class Camera1 extends CameraController implements Camera.PreviewCallback, Camera
}
LOG.e("Error inside the onError callback.", error);
throw new CameraException(new RuntimeException(CameraLogger.lastMessage));
// throw new CameraException(new RuntimeException(CameraLogger.lastMessage));
mCameraCallbacks.dispatchError(new CameraException(new RuntimeException(CameraLogger.lastMessage)));
}
@Override

Loading…
Cancel
Save