diff --git a/doc/designs/quic-design/server/quic-polling.md b/doc/designs/quic-design/server/quic-polling.md index a7757001a3..802fdf48d7 100644 --- a/doc/designs/quic-design/server/quic-polling.md +++ b/doc/designs/quic-design/server/quic-polling.md @@ -408,7 +408,7 @@ issues with this design: This limitation is intrinsic to the design of `poll(2)` and poll-esque APIs. It is not necessarily a reason not to offer this rather simple API, as use of poll(2) and poll(2)-like APIs is widespread and users are likely to appreciate - an API which does not provide significant impedence discontinuities to + an API which does not provide significant impedance discontinuities to applications which use select/poll, even if those applications suffer impaired performance as a result. @@ -1424,7 +1424,7 @@ socket handle and then closes it. What happens?** Since OSes in general do not provide a way to get notified of these closures it is not really possible to handle this automatically. It is essential that an -application deregister the handle from the poll group first. +application deregisters the handle from the poll group first. **Q. How does code using a poll method determine what poll descriptors that method supports?** diff --git a/ssl/quic/quic_obj_local.h b/ssl/quic/quic_obj_local.h index d0cfa4165b..fa5b33f265 100644 --- a/ssl/quic/quic_obj_local.h +++ b/ssl/quic/quic_obj_local.h @@ -30,7 +30,7 @@ * * The QUIC_OBJ is a base type for QUIC APL objects which provides functionality * common to all QUIC objects and which supports having different APL objects - * dynamically assume leader roles. It can therefore be seen as an extention of + * dynamically assume leader roles. It can therefore be seen as an extension of * the SSL base class and extends the SSL object for QUIC APL objects. This * avoids duplication of functionality for different types of QUIC object and * allows access to common responsibilities of different types of APL object @@ -64,8 +64,8 @@ * * This structure must come at the start of a QUIC object structure definition. * - * ssl->type still determines the actual object type. An SSL object pointer s - * can be safely cast to (QUIC_OBJ *) iff IS_QUIC(s) is true. + * ssl->type still determines the actual object type. An SSL object + * pointer s can be safely cast to (QUIC_OBJ *) iff IS_QUIC(s) is true. */ struct quic_obj_st { /* SSL object common header. */ @@ -105,6 +105,11 @@ struct quic_obj_st { unsigned int is_port_leader : 1; }; +/* + * Core Functions and Inlines + * ========================== + */ + /* * Initialises a QUIC_OBJ structure with zero or more roles active. Returns 1 * on success or 0 on failure. @@ -217,6 +222,8 @@ ossl_quic_obj_get0_port_local(const QUIC_OBJ *obj) /* * Convenience Inlines * =================== + * + * These inlines are expressed in terms of the core functions and inlines above. */ /* Get a pointer to the QUIC domain mutex. Always returns non-NULL. */ diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 2a575a7598..2a160d34b9 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -7702,11 +7702,11 @@ SSL *SSL_get0_listener(SSL *s) { #ifndef OPENSSL_NO_QUIC if (!IS_QUIC(s)) - return s; + return NULL; return ossl_quic_get0_listener(s); #else - return s; + return NULL; #endif } diff --git a/ssl/t1_trce.c b/ssl/t1_trce.c index 37cab668de..0daaecefa7 100644 --- a/ssl/t1_trce.c +++ b/ssl/t1_trce.c @@ -14,9 +14,7 @@ /* Packet trace support for OpenSSL */ #include "internal/nelem.h" #include "internal/ssl_unwrap.h" -#include "internal/quic_predef.h" #include "internal/quic_trace.h" -#include "quic/quic_local.h" typedef struct { int num; diff --git a/test/radix/quic_bindings.c b/test/radix/quic_bindings.c index 03d8e48a8b..f2eb1474cf 100644 --- a/test/radix/quic_bindings.c +++ b/test/radix/quic_bindings.c @@ -114,7 +114,11 @@ static RADIX_OBJ *RADIX_OBJ_new(const char *name, SSL *ssl) if (!TEST_ptr(obj = OPENSSL_zalloc(sizeof(*obj)))) return NULL; - obj->name = OPENSSL_strdup(name); + if (!TEST_ptr(obj->name = OPENSSL_strdup(name))) { + OPENSSL_free(obj); + return NULL; + } + obj->ssl = ssl; return obj; } diff --git a/test/radix/quic_ops.c b/test/radix/quic_ops.c index 0a60176590..955a5cb83f 100644 --- a/test/radix/quic_ops.c +++ b/test/radix/quic_ops.c @@ -587,7 +587,7 @@ DEF_FUNC(hf_connect_wait) goto err; if (ret != 1) { - if (1 /* TODO */ && is_want(ssl, ret)) + if (is_want(ssl, ret)) F_SPIN_AGAIN(); if (!TEST_int_eq(ret, 1))