diff options
author | Niklas Söderlund <niklas.soderlund@ragnatech.se> | 2020-06-01 22:53:24 +0200 |
---|---|---|
committer | Niklas Söderlund <niklas.soderlund@ragnatech.se> | 2020-06-22 17:00:41 +0200 |
commit | 72b9b7d3f33a5540d726bf0e00c29ac95b07cc48 (patch) | |
tree | bcabbb95d2c9d2a78dc3e1d670e8c2d5f11483e3 | |
parent | 846e7d999a15ce0c3784a790cd5c249ba7aaa5c6 (diff) |
libcamera: stream: Initialize stride and bufferCount
The two public unsigned integer fields of StreamConfiguration, stride
and bufferCount where not initialized, fix this to match other members
being initialized to their 'zero' state.
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>
-rw-r--r-- | src/libcamera/stream.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/libcamera/stream.cpp b/src/libcamera/stream.cpp index 8e782347..6df5882f 100644 --- a/src/libcamera/stream.cpp +++ b/src/libcamera/stream.cpp @@ -279,7 +279,7 @@ SizeRange StreamFormats::range(const PixelFormat &pixelformat) const * handlers provide StreamFormats. */ StreamConfiguration::StreamConfiguration() - : pixelFormat(0), stream_(nullptr) + : pixelFormat(0), stride(0), bufferCount(0), stream_(nullptr) { } @@ -287,7 +287,8 @@ StreamConfiguration::StreamConfiguration() * \brief Construct a configuration with stream formats */ StreamConfiguration::StreamConfiguration(const StreamFormats &formats) - : pixelFormat(0), stream_(nullptr), formats_(formats) + : pixelFormat(0), stride(0), bufferCount(0), stream_(nullptr), + formats_(formats) { } |