MINOR: cli/show_fd: report that a connection is back or not
It simply adds a "back={0,1}" depending on the connection's side, it's useful to debug.
This commit is contained in:
parent
6dea2ee939
commit
e9ca80711d
@ -888,6 +888,7 @@ static int cli_io_handler_show_fd(struct appctx *appctx)
|
|||||||
const struct mux_ops *mux = NULL;
|
const struct mux_ops *mux = NULL;
|
||||||
void *ctx = NULL;
|
void *ctx = NULL;
|
||||||
uint32_t conn_flags = 0;
|
uint32_t conn_flags = 0;
|
||||||
|
int is_back = 0;
|
||||||
|
|
||||||
fdt = fdtab[fd];
|
fdt = fdtab[fd];
|
||||||
|
|
||||||
@ -901,6 +902,7 @@ static int cli_io_handler_show_fd(struct appctx *appctx)
|
|||||||
li = objt_listener(((struct connection *)fdt.owner)->target);
|
li = objt_listener(((struct connection *)fdt.owner)->target);
|
||||||
sv = objt_server(((struct connection *)fdt.owner)->target);
|
sv = objt_server(((struct connection *)fdt.owner)->target);
|
||||||
px = objt_proxy(((struct connection *)fdt.owner)->target);
|
px = objt_proxy(((struct connection *)fdt.owner)->target);
|
||||||
|
is_back = conn_is_back((struct connection *)fdt.owner);
|
||||||
}
|
}
|
||||||
else if (fdt.iocb == listener_accept)
|
else if (fdt.iocb == listener_accept)
|
||||||
li = fdt.owner;
|
li = fdt.owner;
|
||||||
@ -936,7 +938,7 @@ static int cli_io_handler_show_fd(struct appctx *appctx)
|
|||||||
"unknown");
|
"unknown");
|
||||||
|
|
||||||
if (fdt.iocb == conn_fd_handler) {
|
if (fdt.iocb == conn_fd_handler) {
|
||||||
chunk_appendf(&trash, " cflg=0x%08x", conn_flags);
|
chunk_appendf(&trash, " back=%d cflg=0x%08x", is_back, conn_flags);
|
||||||
if (px)
|
if (px)
|
||||||
chunk_appendf(&trash, " px=%s", px->id);
|
chunk_appendf(&trash, " px=%s", px->id);
|
||||||
else if (sv)
|
else if (sv)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user