From 20cdcfadaca6ce52ac8d80c4203f89ab957b81f0 Mon Sep 17 00:00:00 2001 From: Mahmoud Al-Qudsi Date: Wed, 16 Jan 2019 15:46:11 -0600 Subject: [PATCH] Remove write-only assignments from `autload.cpp` --- src/autoload.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/autoload.cpp b/src/autoload.cpp index bcd980796..a3ad207c1 100644 --- a/src/autoload.cpp +++ b/src/autoload.cpp @@ -134,11 +134,10 @@ autoload_function_t *autoload_t::get_autoloaded_function_with_creation(const wcs ASSERT_IS_LOCKED(lock); autoload_function_t *func = this->get(cmd); if (!func) { - bool added; if (allow_eviction) { - added = this->insert(cmd, autoload_function_t(false)); + this->insert(cmd, autoload_function_t(false)); } else { - added = this->insert_no_eviction(cmd, autoload_function_t(false)); + this->insert_no_eviction(cmd, autoload_function_t(false)); } func = this->get(cmd); assert(func);