summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorNiklas Söderlund <niklas.soderlund@ragnatech.se>2019-02-26 02:20:51 +0100
committerNiklas Söderlund <niklas.soderlund@ragnatech.se>2019-02-27 17:21:40 +0100
commit9aceed70a2879802c7fe00ea2c0455ccd5c14f07 (patch)
tree26ba24dccc44035482fd9ec336011bb64f8944b0 /src
parent374c102073bf8712dc5433f778ca39f85bb97f9c (diff)
libcamera: camera: fix bug in error check for streamConfiguration()
The return statement is missing altogether and an error is silently ignored. Fix this and also update the empty map to use the correct type for the map key. Fixes: 65ea2422d24a3073 ("libcamera: camera: extend camera object to support configuration of streams") Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src')
-rw-r--r--src/libcamera/camera.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp
index 1acb399c..6409d10f 100644
--- a/src/libcamera/camera.cpp
+++ b/src/libcamera/camera.cpp
@@ -213,7 +213,7 @@ std::map<Stream *, StreamConfiguration>
Camera::streamConfiguration(std::vector<Stream *> &streams)
{
if (disconnected_ || !streams.size())
- std::map<unsigned int, StreamConfiguration> {};
+ return std::map<Stream *, StreamConfiguration>{};
return pipe_->streamConfiguration(this, streams);
}