summaryrefslogtreecommitdiffstats
path: root/lib/libcrypto/dsa/dsa_ameth.c
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2014-05-30 06:22:57 +0000
committerderaadt <deraadt@openbsd.org>2014-05-30 06:22:57 +0000
commit0b1e30339eeb8f43097c86a51e3f4e526dce5d73 (patch)
tree4adc99aff640e367a82c027f2de70634404f66a1 /lib/libcrypto/dsa/dsa_ameth.c
parentWhile working on another diff I ended up looking to see why on earth the (diff)
downloadwireguard-openbsd-0b1e30339eeb8f43097c86a51e3f4e526dce5d73.tar.xz
wireguard-openbsd-0b1e30339eeb8f43097c86a51e3f4e526dce5d73.zip
more: no need for null check before free
ok tedu guenther
Diffstat (limited to 'lib/libcrypto/dsa/dsa_ameth.c')
-rw-r--r--lib/libcrypto/dsa/dsa_ameth.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/libcrypto/dsa/dsa_ameth.c b/lib/libcrypto/dsa/dsa_ameth.c
index 16617d40f5b..e2c3980e565 100644
--- a/lib/libcrypto/dsa/dsa_ameth.c
+++ b/lib/libcrypto/dsa/dsa_ameth.c
@@ -342,8 +342,7 @@ static int dsa_priv_encode(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pkey)
return 1;
err:
- if (dp != NULL)
- free(dp);
+ free(dp);
if (params != NULL)
ASN1_STRING_free(params);
if (prkey != NULL)