MCPcopy Create free account
hub / github.com/ElementsProject/lightning / json_stream_raw_for_cmd

Function json_stream_raw_for_cmd

lightningd/jsonrpc.c:686–703  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

684}
685
686struct json_stream *json_stream_raw_for_cmd(struct command *cmd)
687{
688 struct json_stream *js;
689
690 /* Might have already opened it for a notification */
691 if (cmd->json_stream)
692 return cmd->json_stream;
693
694 /* If they still care about the result, attach it to them. */
695 if (cmd->jcon)
696 js = jcon_new_json_stream(cmd, cmd->jcon, cmd);
697 else
698 js = new_json_stream(cmd, cmd, NULL);
699
700 assert(!cmd->json_stream);
701 cmd->json_stream = js;
702 return js;
703}
704
705void json_stream_log_suppress_for_cmd(struct json_stream *js,
706 const struct command *cmd)

Callers 4

plugin_rpcmethod_cbFunction · 0.85
plugin_notify_cbFunction · 0.85
json_notify_fmtFunction · 0.85
json_startFunction · 0.85

Calls 2

jcon_new_json_streamFunction · 0.85
new_json_streamFunction · 0.85

Tested by

no test coverage detected