diff options
author | Matt Caswell <matt@openssl.org> | 2016-04-25 17:45:11 +0100 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2016-04-25 19:47:18 +0100 |
commit | 1ee454157636a69400af56ea19f57c0b05c344ef (patch) | |
tree | f91e81c4cf33f6fb6a96eeebbb62182592ba5459 | |
parent | 184ebf0fca31685bb03e2ed225f2c474769fe646 (diff) |
Fix a signed/unsigned warning
This causes a compilation failure when using --strict-warnings in 1.0.2
and 1.0.1
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
(cherry picked from commit 0ca67644ddedfd656d43a6639d89a6236ff64652)
-rw-r--r-- | crypto/asn1/asn1_lib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/asn1/asn1_lib.c b/crypto/asn1/asn1_lib.c index 54b683c151..874b1af8b0 100644 --- a/crypto/asn1/asn1_lib.c +++ b/crypto/asn1/asn1_lib.c @@ -175,7 +175,7 @@ static int asn1_get_length(const unsigned char **pp, int *inf, long *rl, *inf = 0; i = *p & 0x7f; if (*(p++) & 0x80) { - if (i > sizeof(ret) || max < i) + if (i > sizeof(ret) || max < (long)i) return 0; while (i-- > 0) { ret <<= 8L; |