MINOR: stream/cli: fix the location of the waiting flag in "show sess all"

The "waiting" flag indicates if the stream is waiting for some memory,
and was placed on the same output line as the txn for ease of reading.
But since 1.6 the txn is not part of the stream anymore so this output
was placed under a condition, resulting in "waiting" to appear only
when a txn is present. Let's move it upper, closer to the stream's
flags to fix this.

This may safely be backported though it has little value for older
versions.
This commit is contained in:
Willy Tarreau 2019-01-07 10:10:07 +01:00
parent b84e67fee9
commit adf7a15bd1

View File

@ -2850,8 +2850,9 @@ static int stats_dump_full_strm_to_buffer(struct stream_interface *si, struct st
}
chunk_appendf(&trash,
" flags=0x%x, conn_retries=%d, srv_conn=%p, pend_pos=%p\n",
strm->flags, strm->si[1].conn_retries, strm->srv_conn, strm->pend_pos);
" flags=0x%x, conn_retries=%d, srv_conn=%p, pend_pos=%p waiting=%d\n",
strm->flags, strm->si[1].conn_retries, strm->srv_conn, strm->pend_pos,
!LIST_ISEMPTY(&strm->buffer_wait.list));
chunk_appendf(&trash,
" frontend=%s (id=%u mode=%s), listener=%s (id=%u)",
@ -2950,9 +2951,9 @@ static int stats_dump_full_strm_to_buffer(struct stream_interface *si, struct st
if (strm->txn)
chunk_appendf(&trash,
" txn=%p flags=0x%x meth=%d status=%d req.st=%s rsp.st=%s waiting=%d\n",
" txn=%p flags=0x%x meth=%d status=%d req.st=%s rsp.st=%s\n",
strm->txn, strm->txn->flags, strm->txn->meth, strm->txn->status,
h1_msg_state_str(strm->txn->req.msg_state), h1_msg_state_str(strm->txn->rsp.msg_state), !LIST_ISEMPTY(&strm->buffer_wait.list));
h1_msg_state_str(strm->txn->req.msg_state), h1_msg_state_str(strm->txn->rsp.msg_state));
chunk_appendf(&trash,
" si[0]=%p (state=%s flags=0x%02x endp0=%s:%p exp=%s et=0x%03x sub=%d)\n",