From 404352fc7eb7319b71b928664b08c2dd3d5b6dd0 Mon Sep 17 00:00:00 2001 From: Christian Decker Date: Fri, 2 Nov 2018 20:04:32 +0100 Subject: [PATCH] plugin: Configure plugins once we've collected all cli options --- lightningd/plugin.c | 4 ++++ lightningd/plugin.h | 9 +++++++++ 2 files changed, 13 insertions(+) diff --git a/lightningd/plugin.c b/lightningd/plugin.c index 8de88edae..65e6fe85d 100644 --- a/lightningd/plugin.c +++ b/lightningd/plugin.c @@ -411,6 +411,10 @@ void plugins_init(struct plugins *plugins) io_loop(NULL, NULL); } +void plugins_config(struct plugins *plugins) +{ +} + void json_add_opt_plugins(struct json_stream *response, const struct plugins *plugins) { diff --git a/lightningd/plugin.h b/lightningd/plugin.h index 1b3f1df9c..d3988a01a 100644 --- a/lightningd/plugin.h +++ b/lightningd/plugin.h @@ -37,6 +37,15 @@ void plugins_init(struct plugins *plugins); */ void plugin_register(struct plugins *plugins, const char* path TAKES); +/** + * Send the configure message to all plugins. + * + * Once we've collected all the command line arguments we can go ahead + * and send them over to the plugin. This finalizes the initialization + * of the plugins and signals that lightningd is now ready to process + * incoming JSON-RPC calls and messages. + */ +void plugins_config(struct plugins *plugins); /** * Add the plugin option and their respective options to listconfigs. *