plugins: do I/O logging.

I was trying to trace a problem with a plugin, and needed this.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2019-05-31 11:31:07 +09:30
committed by Christian Decker
parent 48df6c8566
commit 8f9c48254b
5 changed files with 26 additions and 5 deletions

View File

@@ -74,8 +74,8 @@ void plugin_hook_call_(struct lightningd *ld, const struct plugin_hook *hook,
* currently have a list to store these. We might want
* to eventually to inspect in-flight requests. */
ph_req = notleak(tal(hook->plugin, struct plugin_hook_request));
/* FIXME: do IO logging for these! */
req = jsonrpc_request_start(NULL, hook->name, NULL,
req = jsonrpc_request_start(NULL, hook->name,
plugin_get_log(hook->plugin),
plugin_hook_callback, ph_req);
ph_req->hook = hook;
ph_req->cb_arg = cb_arg;