summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHugo Landau <hlandau@openssl.org>2023-08-30 08:01:47 +0100
committerHugo Landau <hlandau@openssl.org>2023-09-06 10:32:14 +0100
commit769c9b1a99b4bb7878a7b4d031d928376de1b8c3 (patch)
tree1bda59056b92b7a7b18626c6ff9415de7c216d91
parent425a780462d387a81c83fd2b87d0efd91d6b154b (diff)
QUIC MULTISTREAM TEST: Adjust spin behaviour
Reviewed-by: Tomas Mraz <tomas@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/21827)
-rw-r--r--test/quic_multistream_test.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/test/quic_multistream_test.c b/test/quic_multistream_test.c
index bc32708d72..1138e3e1e6 100644
--- a/test/quic_multistream_test.c
+++ b/test/quic_multistream_test.c
@@ -1005,14 +1005,24 @@ static int run_script_worker(struct helper *h, const struct script_op *script,
if (!TEST_true(helper_local_init(hl, h, thread_idx)))
goto out;
-#define S_SPIN_AGAIN() { OSSL_sleep(1); no_advance = 1; continue; }
+#define COMMON_SPIN_AGAIN() \
+ { \
+ no_advance = 1; \
+ continue; \
+ }
+#define S_SPIN_AGAIN() \
+ { \
+ s_lock(h, hl); \
+ ossl_quic_tserver_tick(h->s); \
+ COMMON_SPIN_AGAIN(); \
+ }
#define C_SPIN_AGAIN() \
{ \
if (h->blocking) { \
TEST_error("spin again in blocking mode"); \
goto out; \
} \
- S_SPIN_AGAIN(); \
+ COMMON_SPIN_AGAIN(); \
}
for (;;) {