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

Function destroy_jcon

lightningd/jsonrpc.c:138–147  ·  view source on GitHub ↗

jcon and cmd have separate lifetimes: we detach them on either destruction */

Source from the content-addressed store, hash-verified

136
137/* jcon and cmd have separate lifetimes: we detach them on either destruction */
138static void destroy_jcon(struct json_connection *jcon)
139{
140 struct command *c;
141
142 list_for_each(&jcon->commands, c, list)
143 c->jcon = NULL;
144
145 /* Make sure this happens last! */
146 tal_free(jcon->log);
147}
148
149struct logger *command_logger(struct command *cmd)
150{

Callers

nothing calls this directly

Calls 1

tal_freeFunction · 0.85

Tested by

no test coverage detected