Commit ca354bdd authored by Dag Haavi Finstad's avatar Dag Haavi Finstad Committed by Dridi Boukelmoune

Ensure that only the rxthread gets to use h2->cond in h2_send_get

Future-proofing to avoid mistakenly introducing another race down the
line.
parent a6533c74
......@@ -45,6 +45,8 @@ h2_send_get(struct worker *wrk, struct h2_sess *h2, struct h2_req *r2)
CHECK_OBJ_NOTNULL(wrk, WORKER_MAGIC);
Lck_AssertHeld(&h2->sess->mtx);
if (&wrk->cond == h2->cond)
ASSERT_RXTHR(h2);
r2->wrk = wrk;
VTAILQ_INSERT_TAIL(&h2->txqueue, r2, tx_list);
while (VTAILQ_FIRST(&h2->txqueue) != r2)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment