mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 15:14:23 +01:00
plugin: Ensure RPC passthrough calls are terminated when plugin dies
We now track all pending RPC passthrough calls, and terminate them with an error if the plugin dies. Changelog-Fixed: JSON-RPC: Pending RPC method calls are now terminated if the handling plugin exits prematurely.
This commit is contained in:
committed by
Rusty Russell
parent
7ae8e21247
commit
197a144505
@@ -25,6 +25,9 @@ static const errcode_t PARAM_DEV_ERROR = -2;
|
||||
/* Plugin returned an error */
|
||||
static const errcode_t PLUGIN_ERROR = -3;
|
||||
|
||||
/* Plugin terminated while handling a request. */
|
||||
static const errcode_t PLUGIN_TERMINATED = -4;
|
||||
|
||||
/* Errors from `pay`, `sendpay`, or `waitsendpay` commands */
|
||||
static const errcode_t PAY_IN_PROGRESS = 200;
|
||||
static const errcode_t PAY_RHASH_ALREADY_USED = 201;
|
||||
|
||||
Reference in New Issue
Block a user