Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Log if builtin plugin fails to start #7616

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 13 additions & 8 deletions lightningd/plugin.c
Original file line number Diff line number Diff line change
Expand Up @@ -2536,14 +2536,19 @@ void plugins_set_builtin_plugins_dir(struct plugins *plugins,
const char *dir)
{
/*~ Load the builtin plugins as important. */
for (size_t i = 0; list_of_builtin_plugins[i]; ++i)
plugin_register(plugins,
take(path_join(NULL, dir,
list_of_builtin_plugins[i])),
NULL,
/* important = */
!streq(list_of_builtin_plugins[i], "cln-renepay"),
NULL, NULL);
for (size_t i = 0; list_of_builtin_plugins[i]; ++i) {
struct plugin *p = plugin_register(
plugins,
take(path_join(NULL, dir, list_of_builtin_plugins[i])),
NULL,
/* important = */
!streq(list_of_builtin_plugins[i], "cln-renepay"), NULL,
NULL);
if (!p)
log_unusual(
plugins->log, "failed to register plugin %s",
path_join(tmpctx, dir, list_of_builtin_plugins[i]));
}
}

void shutdown_plugins(struct lightningd *ld)
Expand Down
Loading