mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-18 05:12:45 +01:00
plugin: log response given by plugin if it's invalid JSON.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
fbeef504f5
commit
f653723a85
@ -276,7 +276,8 @@ static bool plugin_read_json_one(struct plugin *plugin)
|
||||
toks = json_parse_input(plugin->buffer, plugin->used, &valid);
|
||||
if (!toks) {
|
||||
if (!valid) {
|
||||
plugin_kill(plugin, "Failed to parse JSON response");
|
||||
plugin_kill(plugin, "Failed to parse JSON response '%.*s'",
|
||||
(int)plugin->used, plugin->buffer);
|
||||
return false;
|
||||
}
|
||||
/* We need more. */
|
||||
|
Loading…
Reference in New Issue
Block a user