summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKieran Bingham <kieran.bingham@ideasonboard.com>2021-08-10 16:52:15 +0100
committerKieran Bingham <kieran.bingham@ideasonboard.com>2021-09-09 15:58:23 +0100
commit3d297f7ac840c3abe8e72d525f0fbc1fe607f94d (patch)
tree1c91ded6ebf7e6991da1f01efa5a3b1437bc946e /src
parent0eea207b04ec2764fc4f2bafa1ec6df831a74573 (diff)
libcamera: controls: Use a const ControlValidator
The ControlValidator passed to a ControlList constructor is used, but not modified. Make it const. Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'src')
-rw-r--r--src/libcamera/controls.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libcamera/controls.cpp b/src/libcamera/controls.cpp
index 5c05ba4a..55eec71f 100644
--- a/src/libcamera/controls.cpp
+++ b/src/libcamera/controls.cpp
@@ -821,7 +821,8 @@ ControlList::ControlList()
* controls is provided by controls::controls and can be used as the \a idmap
* argument.
*/
-ControlList::ControlList(const ControlIdMap &idmap, ControlValidator *validator)
+ControlList::ControlList(const ControlIdMap &idmap,
+ const ControlValidator *validator)
: validator_(validator), idmap_(&idmap), infoMap_(nullptr)
{
}
@@ -831,7 +832,8 @@ ControlList::ControlList(const ControlIdMap &idmap, ControlValidator *validator)
* \param[in] infoMap The ControlInfoMap for the control list target object
* \param[in] validator The validator (may be null)
*/
-ControlList::ControlList(const ControlInfoMap &infoMap, ControlValidator *validator)
+ControlList::ControlList(const ControlInfoMap &infoMap,
+ const ControlValidator *validator)
: validator_(validator), idmap_(&infoMap.idmap()), infoMap_(&infoMap)
{
}