summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorNiklas Söderlund <niklas.soderlund@ragnatech.se>2020-03-04 23:51:30 +0100
committerNiklas Söderlund <niklas.soderlund@ragnatech.se>2020-03-06 17:45:48 +0100
commit353851b773a6f2a381e5b4e93598c44bbd42903a (patch)
treee78f81b3268c023e2ab639259c89f2cddf0431d3 /src
parent257df552a454d7afdc339ef88040e986400d2d89 (diff)
libcamera: V4L2BufferCache: Mark Entry::operator==() as const
The comparison operator does not change any state, mark it as const. Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src')
-rw-r--r--src/libcamera/include/v4l2_videodevice.h2
-rw-r--r--src/libcamera/v4l2_videodevice.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/libcamera/include/v4l2_videodevice.h b/src/libcamera/include/v4l2_videodevice.h
index fcf07264..359b3664 100644
--- a/src/libcamera/include/v4l2_videodevice.h
+++ b/src/libcamera/include/v4l2_videodevice.h
@@ -122,7 +122,7 @@ private:
Entry();
Entry(bool free, const FrameBuffer &buffer);
- bool operator==(const FrameBuffer &buffer);
+ bool operator==(const FrameBuffer &buffer) const;
bool free;
diff --git a/src/libcamera/v4l2_videodevice.cpp b/src/libcamera/v4l2_videodevice.cpp
index 99470ce1..d88cb0bd 100644
--- a/src/libcamera/v4l2_videodevice.cpp
+++ b/src/libcamera/v4l2_videodevice.cpp
@@ -256,7 +256,7 @@ V4L2BufferCache::Entry::Entry(bool free, const FrameBuffer &buffer)
planes_.emplace_back(plane);
}
-bool V4L2BufferCache::Entry::operator==(const FrameBuffer &buffer)
+bool V4L2BufferCache::Entry::operator==(const FrameBuffer &buffer) const
{
const std::vector<FrameBuffer::Plane> &planes = buffer.planes();