]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: ssl: fix another null-deref warning in ssl_sock_switchctx_cbk()
authorWilly Tarreau <w@1wt.eu>
Mon, 15 Oct 2018 11:20:07 +0000 (13:20 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 15 Oct 2018 11:24:43 +0000 (13:24 +0200)
This null-deref cannot happen either as there necesarily is a listener
where this function is called. Let's use __objt_listener() to address
this.

This may be backported to 1.8.

src/ssl_sock.c

index baedc33c48313dd78c89ab326cdb26e834ea7bfe..41833768d81f7d012552da4772770010c145365b 100644 (file)
@@ -2127,7 +2127,7 @@ static int ssl_sock_switchctx_cbk(SSL *ssl, int *al, void *arg)
        int i;
 
        conn = SSL_get_ex_data(ssl, ssl_app_data_index);
-       s = objt_listener(conn->target)->bind_conf;
+       s = __objt_listener(conn->target)->bind_conf;
 
        if (s->ssl_conf.early_data)
                allow_early = 1;