From: Hugo Landau Date: Tue, 6 Feb 2024 12:51:53 +0000 (+0000) Subject: QUIC MULTISTREAM Test: Ensure poll test is robust X-Git-Tag: openssl-3.3.0-alpha1~105 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=32a728d4e4722dbd8b419f449544cc68b87ea6f9;p=thirdparty%2Fopenssl.git QUIC MULTISTREAM Test: Ensure poll test is robust Reviewed-by: Neil Horman Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/23495) --- diff --git a/test/quic_multistream_test.c b/test/quic_multistream_test.c index adb5cdb3970..bda30c11d6b 100644 --- a/test/quic_multistream_test.c +++ b/test/quic_multistream_test.c @@ -5468,14 +5468,16 @@ ossl_unused static int script_85_poll(struct helper *h, struct helper_local *hl) ++item; /* Non-zero timeout is not supported. */ - result_count = UINT64_MAX; + result_count = SIZE_MAX; + ERR_set_mark(); if (!TEST_false(SSL_poll(items, OSSL_NELEM(items), sizeof(SSL_POLL_ITEM), &nz_timeout, 0, &result_count)) || !TEST_size_t_eq(result_count, 0)) return 0; - result_count = UINT64_MAX; + ERR_pop_to_mark(); + result_count = SIZE_MAX; ret = SSL_poll(items, OSSL_NELEM(items), sizeof(SSL_POLL_ITEM), &timeout, 0, &result_count); @@ -5553,6 +5555,7 @@ static const struct script_op script_85[] = { OP_SET_INJECT_WORD (C_BIDI_ID(1) + 1, OSSL_QUIC_FRAME_TYPE_RESET_STREAM) /* Ensure sync. */ + OP_S_READ_EXPECT (d, "sync", 4) OP_S_WRITE (d, "x", 1) OP_C_READ_EXPECT (d, "x", 1)