Fix strict-warnings build
authorPatrick Steuer <psteuer@mail.de>
Sat, 15 Oct 2016 14:54:52 +0000 (16:54 +0200)
committerRichard Levitte <levitte@openssl.org>
Thu, 11 May 2017 16:19:11 +0000 (18:19 +0200)
crypto/asn1/a_strex.c: Type of width variable in asn1_valid_host
function  needs to be changed from char to signed char to avoid
build error due to '-Werror=type-limits'.

Signed-off-by: Patrick Steuer <psteuer@mail.de>
Reviewed-by: Rich Salz <rsalz@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
CLA: trivial
(cherry picked from commit 34657a8da2ead453460d668771984432cc767044)

crypto/asn1/a_strex.c

index 9839f5c76eb3e28062f81f5ac193e982c30f8833..1bc06799afa9bef1ab3ded797e96065be15ee866 100644 (file)
@@ -601,7 +601,7 @@ int asn1_valid_host(const ASN1_STRING *host)
     const unsigned char *hostptr = host->data;
     int type = host->type;
     int i;
-    char width = -1;
+    signed char width = -1;
     unsigned short chflags = 0, prevchflags;
 
     if (type > 0 && type < 31)