summaryrefslogtreecommitdiff
path: root/test/v4l2_videodevice/controls.cpp
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-09-23 14:49:46 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-09-24 13:25:33 +0300
commit9b8f4c870fa831c4c4becd4226a2eccfc84f5110 (patch)
tree067251af757e8415ee791e2c04b09a6630ab14d2 /test/v4l2_videodevice/controls.cpp
parentd4e15331cb593c1a681a79940805c008af5bcb18 (diff)
android: camera_device: Return unique_ptr from createFrameBuffer
Returning a non-managed pointer can cause leaks. Use a unique_ptr<> instead to avoid possible future issues. The std::move() for the planes argument to the FrameBuffer constructor is dropped as it's misleading. FrameBuffer has no constructor that takes an rvalue reference to planes, so the vector was copied despite the move. This only clarifies the intent, no functional change is introduced. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Hirokazu Honda <hiroh@chromium.org> Reviewed-by: Umang Jain <umang.jain@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
Diffstat (limited to 'test/v4l2_videodevice/controls.cpp')
0 files changed, 0 insertions, 0 deletions