diff --git a/lib/activate/activate.c b/lib/activate/activate.c index 2328abe61..58e687321 100644 --- a/lib/activate/activate.c +++ b/lib/activate/activate.c @@ -1662,7 +1662,10 @@ static struct dm_event_handler *_create_dm_event_handler(struct cmd_context *cmd if (!(dmevh = dm_event_handler_create())) return_NULL; - if (dm_event_handler_set_dmeventd_path(dmevh, find_config_tree_str(cmd, dmeventd_executable_CFG, NULL))) + if (!cmd->default_settings.dmeventd_executable) + cmd->default_settings.dmeventd_executable = find_config_tree_str(cmd, dmeventd_executable_CFG, NULL); + + if (dm_event_handler_set_dmeventd_path(dmevh, cmd->default_settings.dmeventd_executable)) goto_bad; if (dso && dm_event_handler_set_dso(dmevh, dso)) diff --git a/lib/commands/toolcontext.h b/lib/commands/toolcontext.h index 4419daab8..392116725 100644 --- a/lib/commands/toolcontext.h +++ b/lib/commands/toolcontext.h @@ -42,6 +42,7 @@ struct config_info { int cache_vgmetadata; const char *msg_prefix; const char *fmt_name; + const char *dmeventd_executable; uint64_t unit_factor; int cmd_name; /* Show command name? */ mode_t umask;