CLEANUP: stream: Remove useless tests on conn-stream in stream_dump()
Since the recent refactoring on the conn-streams, a stream has always a
defined frontend and backend conn-streams. Thus, in stream_dump(), there is
no reason to still test if these conn-streams are defined.
In addition, still in stream_dump(), get the stream-interfaces using the
conn-streams and not the opposite.
This patch should fix issue #1589 and #1590.
diff --git a/src/stream.c b/src/stream.c
index 27b6863..323b6b9 100644
--- a/src/stream.c
+++ b/src/stream.c
@@ -2713,12 +2713,11 @@
return;
}
- si_f = cs_si(s->csf);
- si_b = cs_si(s->csb);
req = &s->req;
res = &s->res;
- csf = si_f->cs;
+ csf = s->csf;
+ si_f = cs_si(csf);
cof = cs_conn(csf);
acf = cs_appctx(csf);
if (cof && cof->src && addr_to_str(cof->src, pn, sizeof(pn)) >= 0)
@@ -2726,7 +2725,8 @@
else if (acf)
src = acf->applet->name;
- csb = si_b->cs;
+ csb = s->csb;
+ si_b = cs_si(csb);
cob = cs_conn(csb);
acb = cs_appctx(csb);
srv = objt_server(s->target);
@@ -2751,7 +2751,7 @@
pfx, req->flags, req->analysers, res->flags, res->analysers,
si_state_str(si_f->state), si_f->flags,
si_state_str(si_b->state), si_b->flags, eol,
- pfx, csf, csf ? csf->flags : 0, csb, csb ? csb->flags : 0, eol,
+ pfx, csf, csf->flags, csb, csb->flags, eol,
pfx, acf, acf ? acf->st0 : 0, acb, acb ? acb->st0 : 0, eol,
pfx, cof, cof ? cof->flags : 0, conn_get_mux_name(cof), cof?cof->ctx:0, conn_get_xprt_name(cof),
cof ? cof->xprt_ctx : 0, conn_get_ctrl_name(cof), cof ? cof->handle.fd : 0, eol,