CLEANUP: muxes: Remove useless if condition in show_fd function
In H1, H2 and FCGI muxes, in the show_fd function, there is duplicated test on
the stream's subs field.
This patch fixes the issue #1142. It may be backported as far as 2.2.
(cherry picked from commit 6c93c4ef089fc79ce4e85fa0d9e7f61720291dba)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
diff --git a/src/mux_fcgi.c b/src/mux_fcgi.c
index 9efb96c..a8528e8 100644
--- a/src/mux_fcgi.c
+++ b/src/mux_fcgi.c
@@ -4104,14 +4104,12 @@
fstrm->cs->flags, fstrm->cs->data);
chunk_appendf(&trash, " .subs=%p", fstrm->subs);
if (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=",
- fstrm->subs->tasklet->calls,
- fstrm->subs->tasklet->context);
- resolve_sym_name(&trash, NULL, fstrm->subs->tasklet->process);
- chunk_appendf(&trash, ")");
- }
+ chunk_appendf(&trash, "(ev=%d tl=%p", fstrm->subs->events, fstrm->subs->tasklet);
+ chunk_appendf(&trash, " 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, ")");
}
}
return 0;