summaryrefslogtreecommitdiffstats
path: root/database
diff options
context:
space:
mode:
Diffstat (limited to 'database')
-rw-r--r--database/rrdhost.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/database/rrdhost.c b/database/rrdhost.c
index 3bde0ee178..5fc1021388 100644
--- a/database/rrdhost.c
+++ b/database/rrdhost.c
@@ -631,7 +631,7 @@ RRDHOST *rrdhost_find_or_create(
rrd_wrlock();
RRDHOST *host = rrdhost_find_by_guid(guid);
- if (unlikely(host && RRD_MEMORY_MODE_DBENGINE != mode && rrdhost_flag_check(host, RRDHOST_FLAG_ARCHIVED))) {
+ if (unlikely(host && host->rrd_memory_mode != mode && rrdhost_flag_check(host, RRDHOST_FLAG_ARCHIVED))) {
/* If a legacy memory mode instantiates all dbengine state must be discarded to avoid inconsistencies */
error("Archived host '%s' has memory mode '%s', but the wanted one is '%s'. Discarding archived state.",
rrdhost_hostname(host), rrd_memory_mode_name(host->rrd_memory_mode), rrd_memory_mode_name(mode));