diff options
author | Matt Caswell <matt@openssl.org> | 2015-09-16 10:47:15 +0100 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2015-09-17 22:31:24 +0100 |
commit | 197db2143c9e0324300cc631740844df651a05ff (patch) | |
tree | da9808f7683001319efb78e93d01fce6383a78cb /crypto/dsa | |
parent | cb71f17dc786c72ec74c0ebb983b3ccfde484271 (diff) |
Make sure OPENSSL_cleanse checks for NULL
In master we have the function OPENSSL_clear_free(x,y), which immediately
returns if x == NULL. In <=1.0.2 this function does not exist so we have to
do:
OPENSSL_cleanse(x, y);
OPENSSL_free(x);
However, previously, OPENSSL_cleanse did not check that if x == NULL, so
the real equivalent check would have to be:
if (x != NULL)
OPENSSL_cleanse(x, y);
OPENSSL_free(x);
It would be easy to get this wrong during cherry-picking to other branches
and therefore, for safety, it is best to just ensure OPENSSL_cleanse also
checks for NULL.
Reviewed-by: Rich Salz <rsalz@openssl.org>
(cherry picked from commit 020d8fc83fe1a94232db1ee1166309e2458a8a18)
Diffstat (limited to 'crypto/dsa')
0 files changed, 0 insertions, 0 deletions