about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2017-01-24T09·55+0100
committerEelco Dolstra <edolstra@gmail.com>2017-01-24T09·57+0100
commite5641dfe1e9f8afde21939b62d5b2daea3a50241 (patch)
tree1876140cb8ae40424afc15c8630d804ffd9aaeb6
parent1102c77919765b22824ee481afd3bbd618ddb457 (diff)
Work around a bug in clang and older versions of gcc
http://hydra.nixos.org/build/46597440

https://llvm.org/bugs/show_bug.cgi?id=28096
-rw-r--r--src/libutil/util.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libutil/util.cc b/src/libutil/util.cc
index e9457582810a..52608ac2a016 100644
--- a/src/libutil/util.cc
+++ b/src/libutil/util.cc
@@ -1246,7 +1246,7 @@ std::unique_ptr<InterruptCallback> createInterruptCallback(std::function<void()>
     res->it = interruptCallbacks->end();
     res->it--;
 
-    return res;
+    return std::unique_ptr<InterruptCallback>(res.release());
 }
 
 }