[libcamera-devel] [PATCH] pipeline: rkisp1: Add check for non-existent frame info
Sebastian Fricke
sebastian.fricke at posteo.net
Sun Apr 11 18:48:58 CEST 2021
Add a check, that makes sure that the given FrameBuffer is associated
to a RkISP1FrameInfo instance. The current code tries to access the
frame info without checking if it actually exists.
Fixes: 0eb65e14e libcamera: pipeline: rkisp1: Attach to an IPA
Signed-off-by: Sebastian Fricke <sebastian.fricke at posteo.net>
---
src/libcamera/pipeline/rkisp1/rkisp1.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp
index 03757327..eca7d608 100644
--- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp
+++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp
@@ -1079,6 +1079,8 @@ void PipelineHandlerRkISP1::paramReady(FrameBuffer *buffer)
RkISP1CameraData *data = cameraData(activeCamera_);
RkISP1FrameInfo *info = data->frameInfo_.find(buffer);
+ if (!info)
+ return;
info->paramDequeued = true;
tryCompleteRequest(info->request);
--
2.25.1
More information about the libcamera-devel
mailing list