This is an automated email from the ASF dual-hosted git repository. cliffjansen pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/qpid-proton.git
The following commit(s) were added to refs/heads/main by this push: new d409829 PROTON-2519: TLS Library - null pointer reference d409829 is described below commit d4098290d6c56cd059b87e24dcb83429f8655d20 Author: Cliff Jansen <cliffjan...@apache.org> AuthorDate: Mon Mar 14 22:27:28 2022 -0700 PROTON-2519: TLS Library - null pointer reference --- c/src/tls/openssl.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/c/src/tls/openssl.c b/c/src/tls/openssl.c index 779e2b8..d26836c 100644 --- a/c/src/tls/openssl.c +++ b/c/src/tls/openssl.c @@ -2271,6 +2271,8 @@ static int pn_tls_alpn_cb(SSL *ssn, int pn_tls_config_set_alpn_protocols(pn_tls_config_t *domain, const char **protocols, size_t protocol_count) { unsigned char *wire_bytes; size_t wb_len; + if ((protocols == NULL && protocol_count != 0) || (protocols && protocol_count == 0)) + return PN_ARG_ERR; if (protocols == NULL && protocol_count == 0) { free(domain->alpn_list); domain->alpn_list = NULL; --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@qpid.apache.org For additional commands, e-mail: commits-h...@qpid.apache.org