diff options
author | Andy Polyakov <appro@openssl.org> | 2017-04-15 15:53:50 +0200 |
---|---|---|
committer | Andy Polyakov <appro@openssl.org> | 2017-04-17 21:10:27 +0200 |
commit | 786b6a45fbecc068d0fb8b05252a9228e0661c63 (patch) | |
tree | 80fca98d045718ac14b21e03648613390e405b61 /doc/man3/EVP_PKEY_CTX_new.pod | |
parent | 5c8e9d531ba54d26e4bcbe66710c7c75bf0fc4e9 (diff) | |
download | openssl-786b6a45fbecc068d0fb8b05252a9228e0661c63.tar.gz |
asn1/a_int.c: clean up asn1_get_int64.
Trouble was that integer negation wasn't producing *formally* correct
result in platform-neutral sense. Formally correct thing to do is
-(int64_t)u, but this triggers undefined behaviour for one value that
would still be representable in ASN.1. The trigger was masked with
(int64_t)(0-u), but this is formally inappropriate for values other
than the problematic one. [Also reorder branches to favour most-likely
paths and harmonize asn1_string_set_int64 with asn1_get_int64].]
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/3231)
Diffstat (limited to 'doc/man3/EVP_PKEY_CTX_new.pod')
0 files changed, 0 insertions, 0 deletions