diff --git a/lightningd/plugin.c b/lightningd/plugin.c index 28b84ce80..83a01618a 100644 --- a/lightningd/plugin.c +++ b/lightningd/plugin.c @@ -189,8 +189,6 @@ bool plugin_remove(struct plugins *plugins, const char *name) void plugin_kill(struct plugin *plugin, const char *msg) { log_info(plugin->log, "Killing plugin: %s", msg); - plugin->stop = true; - io_wake(plugin); kill(plugin->pid, SIGKILL); list_del(&plugin->list); @@ -501,8 +499,6 @@ static struct io_plan *plugin_write_json(struct io_conn *conn, { if (tal_count(plugin->js_arr)) { return json_stream_output(plugin->js_arr[0], plugin->stdin_conn, plugin_stream_complete, plugin); - } else if (plugin->stop) { - return io_close(conn); } return io_out_wait(conn, plugin, plugin_write_json, plugin); @@ -1242,7 +1238,6 @@ const char *plugin_send_getmanifest(struct plugin *p) log_debug(p->plugins->log, "started(%u) %s", p->pid, p->cmd); p->buffer = tal_arr(p, char, 64); - p->stop = false; /* Create two connections, one read-only on top of p->stdout, and one * write-only on p->stdin */ diff --git a/lightningd/plugin.h b/lightningd/plugin.h index 51af08179..4460324d6 100644 --- a/lightningd/plugin.h +++ b/lightningd/plugin.h @@ -43,7 +43,6 @@ struct plugin { pid_t pid; char *cmd; struct io_conn *stdin_conn, *stdout_conn; - bool stop; struct plugins *plugins; const char **plugin_path; /* If there's a json command which ordered this to start */