| 703 | } |
| 704 | |
| 705 | void json_stream_log_suppress_for_cmd(struct json_stream *js, |
| 706 | const struct command *cmd) |
| 707 | { |
| 708 | const char *nm = cmd->json_cmd->name; |
| 709 | const char *s = tal_fmt(tmpctx, "Suppressing logging of %s command", nm); |
| 710 | log_io(cmd->jcon->log, LOG_IO_OUT, NULL, s, NULL, 0); |
| 711 | |
| 712 | /* Really shouldn't be used for anything else */ |
| 713 | assert(streq(nm, "getlog")); |
| 714 | js->log = NULL; |
| 715 | } |
| 716 | |
| 717 | static struct json_stream *json_start(struct command *cmd) |
| 718 | { |