From 196ef76962b9653e955dc021c118a739527d2509 Mon Sep 17 00:00:00 2001 From: Matt Benjamin Date: Tue, 1 Dec 2015 15:22:12 -0500 Subject: [PATCH] cohort_lru: fix a maybe uninitialized warning (that seems invalid) Signed-off-by: Matt Benjamin --- src/common/cohort_lru.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/cohort_lru.h b/src/common/cohort_lru.h index b7b58dc52ca..d3afa49fba4 100644 --- a/src/common/cohort_lru.h +++ b/src/common/cohort_lru.h @@ -334,7 +334,7 @@ namespace cohort { T* find(uint64_t hk, const K& k, uint32_t flags) { T* v; Latch lat; - uint32_t slot; + uint32_t slot = 0; lat.p = &(partition_of_scalar(hk)); if (flags & FLAG_LOCK) { lat.lock = &lat.p->lock; @@ -369,7 +369,7 @@ namespace cohort { T* find_latch(uint64_t hk, const K& k, Latch& lat, uint32_t flags) { - uint32_t slot; + uint32_t slot = 0; T* v; lat.p = &(partition_of_scalar(hk)); lat.lock = &lat.p->lock;