BUG/MINOR: mux-fcgi: fix the "show fd" dest buffer for the subscriber
Commit 1776ffb97 ("MINOR: mux-fcgi: make the "show fd" helper also decode
the fstrm subscriber when known") improved the output of "show fd" for the
FCGI mux, but the output is sent to the trash buffer instead of the msg
argument. It turns out that this has no effect right now as the caller
passes the trash but this is risky.
This should be backported to 2.4.
diff --git a/src/mux_fcgi.c b/src/mux_fcgi.c
index 6afa9ad..c93ddd4 100644
--- a/src/mux_fcgi.c
+++ b/src/mux_fcgi.c
@@ -4198,14 +4198,14 @@
chunk_appendf(msg, " .sc.flg=0x%08x .sc.app=%p",
fcgi_strm_sc(fstrm)->flags, fcgi_strm_sc(fstrm)->app);
- chunk_appendf(&trash, " .subs=%p", fstrm->subs);
+ chunk_appendf(msg, " .subs=%p", fstrm->subs);
if (fstrm->subs) {
- chunk_appendf(&trash, "(ev=%d tl=%p", fstrm->subs->events, fstrm->subs->tasklet);
- chunk_appendf(&trash, " tl.calls=%d tl.ctx=%p tl.fct=",
+ chunk_appendf(msg, "(ev=%d tl=%p", fstrm->subs->events, fstrm->subs->tasklet);
+ chunk_appendf(msg, " tl.calls=%d tl.ctx=%p tl.fct=",
fstrm->subs->tasklet->calls,
fstrm->subs->tasklet->context);
- resolve_sym_name(&trash, NULL, fstrm->subs->tasklet->process);
- chunk_appendf(&trash, ")");
+ resolve_sym_name(msg, NULL, fstrm->subs->tasklet->process);
+ chunk_appendf(msg, ")");
}
}
return 0;