MINOR: stream: Report rex/wex value using the sedesc date in trace messages
Becasue read and write timeout are now detected using .lra and .fsb fields
of the stream-endpoint descriptor, it is better to also use these fields to
report read and write expiration date in trace messages. Especially because
old rex and wex fields will be removed.
diff --git a/src/stream.c b/src/stream.c
index 45b24f0..1710a83 100644
--- a/src/stream.c
+++ b/src/stream.c
@@ -221,7 +221,7 @@
/* If txn defined, don't display all channel info */
if (src->verbosity == STRM_VERB_SIMPLE || txn) {
- chunk_appendf(&trace_buf, " req=(%p .fl=0x%08x .exp=,%u)",
+ chunk_appendf(&trace_buf, " req=(%p .fl=0x%08x .exp=%u)",
req, req->flags, req->analyse_exp);
chunk_appendf(&trace_buf, " res=(%p .fl=0x%08x .exp=%u)",
res, res->flags, res->analyse_exp);
@@ -3356,9 +3356,9 @@
(sc_ep_test(scf, SE_FL_T_MUX) ? "CONN" : (sc_ep_test(scf, SE_FL_T_APPLET) ? "APPCTX" : "NONE")),
scf->sedesc->se, sc_ep_get(scf), scf->wait_event.events);
chunk_appendf(&trash, " rex=%s",
- sc_ep_rex(scf) ? human_time(TICKS_TO_MS(sc_ep_rex(scf) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
+ sc_ep_rcv_ex(scf) ? human_time(TICKS_TO_MS(sc_ep_rcv_ex(scf) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
chunk_appendf(&trash, " wex=%s\n",
- sc_ep_wex(scf) ? human_time(TICKS_TO_MS(sc_ep_wex(scf) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
+ sc_ep_snd_ex(scf) ? human_time(TICKS_TO_MS(sc_ep_snd_ex(scf) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
if ((conn = sc_conn(scf)) != NULL) {
if (conn->mux && conn->mux->show_sd) {
@@ -3402,9 +3402,9 @@
(sc_ep_test(scb, SE_FL_T_MUX) ? "CONN" : (sc_ep_test(scb, SE_FL_T_APPLET) ? "APPCTX" : "NONE")),
scb->sedesc->se, sc_ep_get(scb), scb->wait_event.events);
chunk_appendf(&trash, " rex=%s",
- sc_ep_rex(scb) ? human_time(TICKS_TO_MS(sc_ep_rex(scb) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
+ sc_ep_rcv_ex(scb) ? human_time(TICKS_TO_MS(sc_ep_rcv_ex(scb) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
chunk_appendf(&trash, " wex=%s\n",
- sc_ep_wex(scb) ? human_time(TICKS_TO_MS(sc_ep_wex(scb) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
+ sc_ep_snd_ex(scb) ? human_time(TICKS_TO_MS(sc_ep_snd_ex(scb) - now_ms), TICKS_TO_MS(1000)) : "<NEVER>");
if ((conn = sc_conn(scb)) != NULL) {
if (conn->mux && conn->mux->show_sd) {
@@ -3698,24 +3698,24 @@
chunk_appendf(&trash," scf=[%d,%1xh,fd=%d",
curr_strm->scf->state, curr_strm->scf->flags, conn_fd(conn));
chunk_appendf(&trash, ",rex=%s",
- sc_ep_rex(curr_strm->scf) ?
- human_time(TICKS_TO_MS(sc_ep_rex(curr_strm->scf) - now_ms),
+ sc_ep_rcv_ex(curr_strm->scf) ?
+ human_time(TICKS_TO_MS(sc_ep_rcv_ex(curr_strm->scf) - now_ms),
TICKS_TO_MS(1000)) : "");
chunk_appendf(&trash,",wex=%s]",
- sc_ep_wex(curr_strm->scf) ?
- human_time(TICKS_TO_MS(sc_ep_wex(curr_strm->scf) - now_ms),
+ sc_ep_snd_ex(curr_strm->scf) ?
+ human_time(TICKS_TO_MS(sc_ep_snd_ex(curr_strm->scf) - now_ms),
TICKS_TO_MS(1000)) : "");
conn = sc_conn(curr_strm->scb);
chunk_appendf(&trash, " scb=[%d,%1xh,fd=%d",
curr_strm->scb->state, curr_strm->scb->flags, conn_fd(conn));
chunk_appendf(&trash, ",rex=%s",
- sc_ep_rex(curr_strm->scb) ?
- human_time(TICKS_TO_MS(sc_ep_rex(curr_strm->scb) - now_ms),
+ sc_ep_rcv_ex(curr_strm->scb) ?
+ human_time(TICKS_TO_MS(sc_ep_rcv_ex(curr_strm->scb) - now_ms),
TICKS_TO_MS(1000)) : "");
chunk_appendf(&trash, ",wex=%s]",
- sc_ep_wex(curr_strm->scb) ?
- human_time(TICKS_TO_MS(sc_ep_wex(curr_strm->scb) - now_ms),
+ sc_ep_snd_ex(curr_strm->scb) ?
+ human_time(TICKS_TO_MS(sc_ep_snd_ex(curr_strm->scb) - now_ms),
TICKS_TO_MS(1000)) : "");
chunk_appendf(&trash,