summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/android/mm/cros_camera_buffer.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/android/mm/cros_camera_buffer.cpp b/src/android/mm/cros_camera_buffer.cpp
index 86770135..2ac3dc4a 100644
--- a/src/android/mm/cros_camera_buffer.cpp
+++ b/src/android/mm/cros_camera_buffer.cpp
@@ -60,6 +60,11 @@ CameraBuffer::Private::Private([[maybe_unused]] CameraBuffer *cameraBuffer,
registered_(false)
{
bufferManager_ = cros::CameraBufferManager::GetInstance();
+ if (!bufferManager_) {
+ LOG(HAL, Fatal)
+ << "Failed to get cros CameraBufferManager instance";
+ return;
+ }
int ret = bufferManager_->Register(camera3Buffer);
if (ret) {