From 7000cfa47268fb268ce009c516e0f18a04272fc8 Mon Sep 17 00:00:00 2001 From: Patrick Niklaus Date: Mon, 29 May 2017 13:07:48 +0000 Subject: [PATCH] Don't copy the object on WriteOne --- include/storage/io.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/storage/io.hpp b/include/storage/io.hpp index 6a7741ea7..4783473e1 100644 --- a/include/storage/io.hpp +++ b/include/storage/io.hpp @@ -228,7 +228,7 @@ class FileWriter template void WriteFrom(const T &src) { WriteFrom(&src, 1); } - template void WriteOne(const T tmp) { WriteFrom(tmp); } + template void WriteOne(const T &tmp) { WriteFrom(tmp); } void WriteElementCount32(const std::uint32_t count) { WriteOne(count); } void WriteElementCount64(const std::uint64_t count) { WriteOne(count); }