jcon and cmd have separate lifetimes: we detach them on either destruction */
| 136 | |
| 137 | /* jcon and cmd have separate lifetimes: we detach them on either destruction */ |
| 138 | static 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 | |
| 149 | struct logger *command_logger(struct command *cmd) |
| 150 | { |
nothing calls this directly
no test coverage detected