Message ID | 20190226021857.28255-2-niklas.soderlund@ragnatech.se |
---|---|
State | Superseded |
Headers | show |
Series |
|
Related | show |
Hi Niklas, On Tue, Feb 26, 2019 at 03:18:50AM +0100, Niklas Söderlund wrote: > 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. Sorry, forgot to reply. Please add Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Thanks j > > Fixes: 65ea2422d24a3073 ("libcamera: camera: extend camera object to support configuration of streams") > Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> > --- > src/libcamera/camera.cpp | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp > index 1acb399c80a6fd3e..6409d10ff88b2189 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); > } > -- > 2.20.1 > > _______________________________________________ > libcamera-devel mailing list > libcamera-devel@lists.libcamera.org > https://lists.libcamera.org/listinfo/libcamera-devel
Hi Niklas, Thank you for the patch. On Tue, Feb 26, 2019 at 03:18:50AM +0100, Niklas Söderlund wrote: > 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> Oops. Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> > --- > src/libcamera/camera.cpp | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp > index 1acb399c80a6fd3e..6409d10ff88b2189 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); > }
Hi, I have pushed this single patch with Jacopo's and Laurent's tags, thanks! On 2019-02-26 03:18:50 +0100, Niklas Söderlund wrote: > 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> > --- > src/libcamera/camera.cpp | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp > index 1acb399c80a6fd3e..6409d10ff88b2189 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); > } > -- > 2.20.1 >
diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp index 1acb399c80a6fd3e..6409d10ff88b2189 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); }
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> --- src/libcamera/camera.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)