]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MINOR: mux-quic: fix wakeup on qcc_set_error()
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Fri, 3 Jan 2025 09:36:39 +0000 (10:36 +0100)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Fri, 3 Jan 2025 09:39:49 +0000 (10:39 +0100)
The following patch was a major refactoring of QUIC MUX. It removes
pacing specific code path. In particular, qcc_wakeup() utility function
was removed and replaced by its tasklet_wakup() usage.
  41f0472d967b2deb095d5adc8a167da973fbee3d
  MEDIUM: mux-quic: remove pacing specific code on qcc_io_cb

However, an incorrect substitution was performed in qcc_set_error(). As
such, there was no explicit wakeup in case an error is detected by QUIC
MUX or the app protocol layer. This may lead to missing error reporting
to clients.

Fix this by re-add tasklet_wakup() usage into qcc_set_error().

This must be backported up to 3.1 where above patch is scheduled.

src/mux_quic.c

index 6b5f46d5e333ec4d4ed9c9af944f3b01dac56bc8..dac22af35d883470f7fdcbf6dd7427014f046fac 100644 (file)
@@ -743,7 +743,7 @@ void qcc_set_error(struct qcc *qcc, int err, int app)
         * is too tedious too not forget a wakeup outside of this function for
         * the moment.
         */
-       HA_ATOMIC_AND(&qcc->wait_event.tasklet->state, ~TASK_F_USR1);
+       tasklet_wakeup(qcc->wait_event.tasklet);
 }
 
 /* Increment glitch counter for <qcc> connection by <inc> steps. If configured