[openssl-commits] [openssl] master update

kaduk kaduk at openssl.org
Wed Jan 24 19:00:31 UTC 2018


The branch master has been updated
       via  1f82eba718f758757a439e717ea7a5aa8be55f8d (commit)
       via  78d0afaa69c2ec662f6c97b47473c2c6a69d636c (commit)
      from  e23ac62594e85296cb90f70480d156f73207218e (commit)


- Log -----------------------------------------------------------------
commit 1f82eba718f758757a439e717ea7a5aa8be55f8d
Author: Christian Heimes <christian at python.org>
Date:   Sun Jan 21 10:37:59 2018 +0100

    Fix signature of min/max proto getter
    
    The getters for min and max proto version wrongly passed NULL instead of
    0 as third argument to SSL_ctrl() and SSL_CTX_ctrl(). The third argument
    is not used, but the error results in a compiler warning:
    
    warning: passing argument 3 of ‘SSL_CTX_ctrl’ makes integer from pointer without a cast [-Wint-conversion]
    int v = SSL_CTX_get_max_proto_version(self->ctx);
    
    See https://github.com/openssl/openssl/pull/4364
    
    Signed-off-by: Christian Heimes <christian at python.org>
    
    Reviewed-by: Rich Salz <rsalz at openssl.org>
    Reviewed-by: Kurt Roeckx <kurt at roeckx.be>
    Reviewed-by: Ben Kaduk <kaduk at mit.edu>
    (Merged from https://github.com/openssl/openssl/pull/5128)

commit 78d0afaa69c2ec662f6c97b47473c2c6a69d636c
Author: Steffan Karger <steffan.karger at fox-it.com>
Date:   Wed Jan 17 17:06:41 2018 +0100

    Fix SSL_CTX_get_{min,max}_proto_version integer conversion warning
    
    When using the SSL_CTX_get_min_min_version macro while compiling with
    -Wall, my compiler rightfully complains about this construction:
    
    warning: passing argument 3 of ‘SSL_CTX_ctrl’ makes integer from
    pointer without a cast [-Wint-conversion]
    
    These macro's should use 0, instead of NULL, for the third argument,
    like most other SSL_CTX_ctrl 'get' wrappers do.
    
    CLA: trivial
    Signed-off-by: Steffan Karger <steffan.karger at fox-it.com>
    
    Reviewed-by: Matt Caswell <matt at openssl.org>
    Reviewed-by: Kurt Roeckx <kurt at roeckx.be>
    Reviewed-by: Ben Kaduk <kaduk at mit.edu>
    (Merged from https://github.com/openssl/openssl/pull/5099)

-----------------------------------------------------------------------

Summary of changes:
 include/openssl/ssl.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/include/openssl/ssl.h b/include/openssl/ssl.h
index cfb0696..97d2e46 100644
--- a/include/openssl/ssl.h
+++ b/include/openssl/ssl.h
@@ -1406,17 +1406,17 @@ DECLARE_PEM_rw(SSL_SESSION, SSL_SESSION)
 #define SSL_CTX_set_max_proto_version(ctx, version) \
         SSL_CTX_ctrl(ctx, SSL_CTRL_SET_MAX_PROTO_VERSION, version, NULL)
 #define SSL_CTX_get_min_proto_version(ctx) \
-        SSL_CTX_ctrl(ctx, SSL_CTRL_GET_MIN_PROTO_VERSION, NULL, NULL)
+        SSL_CTX_ctrl(ctx, SSL_CTRL_GET_MIN_PROTO_VERSION, 0, NULL)
 #define SSL_CTX_get_max_proto_version(ctx) \
-        SSL_CTX_ctrl(ctx, SSL_CTRL_GET_MAX_PROTO_VERSION, NULL, NULL)
+        SSL_CTX_ctrl(ctx, SSL_CTRL_GET_MAX_PROTO_VERSION, 0, NULL)
 #define SSL_set_min_proto_version(s, version) \
         SSL_ctrl(s, SSL_CTRL_SET_MIN_PROTO_VERSION, version, NULL)
 #define SSL_set_max_proto_version(s, version) \
         SSL_ctrl(s, SSL_CTRL_SET_MAX_PROTO_VERSION, version, NULL)
 #define SSL_get_min_proto_version(s) \
-        SSL_ctrl(s, SSL_CTRL_GET_MIN_PROTO_VERSION, NULL, NULL)
+        SSL_ctrl(s, SSL_CTRL_GET_MIN_PROTO_VERSION, 0, NULL)
 #define SSL_get_max_proto_version(s) \
-        SSL_ctrl(s, SSL_CTRL_GET_MAX_PROTO_VERSION, NULL, NULL)
+        SSL_ctrl(s, SSL_CTRL_GET_MAX_PROTO_VERSION, 0, NULL)
 
 #if OPENSSL_API_COMPAT < 0x10100000L
 /* Provide some compatibility macros for removed functionality. */


More information about the openssl-commits mailing list