diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2020-03-20 00:53:51 +0200 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2020-03-20 16:47:45 +0200 |
commit | 916df9e38d3af191853838ab4f2b0049ee207218 (patch) | |
tree | eec096ac64c3a29b77b7107dee28921b7eb42df6 /src | |
parent | 79fbecea456ccf05a76e23ee9bf61b5b057950c9 (diff) |
libcamera: controls: Move ControlValue size check to controls.cpp
The size of the ControlValue class is checked by a static_assert() to
avoid accidental ABI breakages. There's no need to perform the check
every time controls.h is included, move it to controls.cpp.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/libcamera/controls.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libcamera/controls.cpp b/src/libcamera/controls.cpp index 11cec519..fefd292b 100644 --- a/src/libcamera/controls.cpp +++ b/src/libcamera/controls.cpp @@ -86,6 +86,8 @@ static constexpr size_t ControlValueSize[] = { * \brief Abstract type representing the value of a control */ +static_assert(sizeof(ControlValue) == 16, "Invalid size of ControlValue class"); + /** * \brief Construct an empty ControlValue. */ |