From b334643b681357fdc0fd7ee737ac83cc4e586040 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sat, 20 Jan 2018 19:46:54 +0100 Subject: [PATCH] tag/Pool: use C++11 initializers --- src/tag/Pool.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tag/Pool.cxx b/src/tag/Pool.cxx index df3699d30..2cc7d7484 100644 --- a/src/tag/Pool.cxx +++ b/src/tag/Pool.cxx @@ -37,14 +37,14 @@ static constexpr size_t NUM_SLOTS = 4093; struct TagPoolSlot { TagPoolSlot *next; - uint8_t ref; + uint8_t ref = 1; TagItem item; static constexpr unsigned MAX_REF = std::numeric_limits::max(); TagPoolSlot(TagPoolSlot *_next, TagType type, StringView value) - :next(_next), ref(1) { + :next(_next) { item.type = type; memcpy(item.value, value.data, value.size); item.value[value.size] = 0;