summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/utils.hh2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/utils.hh b/src/utils.hh
index 0e155a37..bd52bf0c 100644
--- a/src/utils.hh
+++ b/src/utils.hh
@@ -196,7 +196,7 @@ template<typename T>
class OnScopeEnd
{
public:
- OnScopeEnd(T func) : m_func(func) {}
+ OnScopeEnd(T func) : m_func(std::move(func)) {}
~OnScopeEnd() { m_func(); }
private:
T m_func;