Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 88ff2c6d authored by George Burgess IV's avatar George Burgess IV Committed by android-build-merger
Browse files

Merge "camera: fix two potential null pointer uses" am: bf432cce am: ba1a5300

am: 32a78e18

Change-Id: I94a88acd4ce70d5ff733fd33c27c49cd0bc9f76b
parents 119bc0a2 32a78e18
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -397,9 +397,11 @@ void CameraDevice::sPutMemory(camera_memory_t *data) {
    CameraDevice* device = mem->handle.mDevice;
    if (device == nullptr) {
        ALOGE("%s: camera HAL return memory for a null device!", __FUNCTION__);
        return;
    }
    if (device->mDeviceCallback == nullptr) {
        ALOGE("%s: camera HAL return memory while camera is not opened!", __FUNCTION__);
        return;
    }
    device->mDeviceCallback->unregisterMemory(mem->handle.mId);
    {