diff --git a/lib/config/config.c b/lib/config/config.c index 2c77f3076..d1cf590ff 100644 --- a/lib/config/config.c +++ b/lib/config/config.c @@ -577,7 +577,11 @@ int config_def_check(struct cmd_context *cmd, int force, int skip, int suppress_ cmd->cft_def_hash = NULL; r = 0; goto out; } - dm_hash_insert(cmd->cft_def_hash, vp, def); + if (!dm_hash_insert(cmd->cft_def_hash, vp, def)) { + log_error("Failed to insert configuration to hash."); + r = 0; + goto out; + } } }