diff options
| author | doug <> | 2015-07-19 01:20:32 +0000 | 
|---|---|---|
| committer | doug <> | 2015-07-19 01:20:32 +0000 | 
| commit | 62d7339aa35a88f06d1e898af76c072d9389a792 (patch) | |
| tree | eb49fecfb196ce1e5e23087aae8263a97a5ff794 | |
| parent | cb02139d5c697e3f07cb74f1a5c182020774d9d8 (diff) | |
| download | openbsd-62d7339aa35a88f06d1e898af76c072d9389a792.tar.gz openbsd-62d7339aa35a88f06d1e898af76c072d9389a792.tar.bz2 openbsd-62d7339aa35a88f06d1e898af76c072d9389a792.zip | |
Remove case that can never happen.
It's a little convoluted due to gotos, but at that point, pci is always
NULL.  Spotted by Coverity 21702.
ok miod@ beck@ bcook@
| -rw-r--r-- | src/lib/libcrypto/x509v3/v3_pci.c | 6 | ||||
| -rw-r--r-- | src/lib/libssl/src/crypto/x509v3/v3_pci.c | 6 | 
2 files changed, 2 insertions, 10 deletions
| diff --git a/src/lib/libcrypto/x509v3/v3_pci.c b/src/lib/libcrypto/x509v3/v3_pci.c index d3f73352d9..d19f5a6e61 100644 --- a/src/lib/libcrypto/x509v3/v3_pci.c +++ b/src/lib/libcrypto/x509v3/v3_pci.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: v3_pci.c,v 1.8 2014/07/11 08:44:49 jsing Exp $ */ | 1 | /* $OpenBSD: v3_pci.c,v 1.9 2015/07/19 01:20:32 doug Exp $ */ | 
| 2 | /* Contributed to the OpenSSL Project 2004 | 2 | /* Contributed to the OpenSSL Project 2004 | 
| 3 | * by Richard Levitte (richard@levitte.org) | 3 | * by Richard Levitte (richard@levitte.org) | 
| 4 | */ | 4 | */ | 
| @@ -317,10 +317,6 @@ err: | |||
| 317 | ASN1_OCTET_STRING_free(policy); | 317 | ASN1_OCTET_STRING_free(policy); | 
| 318 | policy = NULL; | 318 | policy = NULL; | 
| 319 | } | 319 | } | 
| 320 | if (pci) { | ||
| 321 | PROXY_CERT_INFO_EXTENSION_free(pci); | ||
| 322 | pci = NULL; | ||
| 323 | } | ||
| 324 | end: | 320 | end: | 
| 325 | sk_CONF_VALUE_pop_free(vals, X509V3_conf_free); | 321 | sk_CONF_VALUE_pop_free(vals, X509V3_conf_free); | 
| 326 | return pci; | 322 | return pci; | 
| diff --git a/src/lib/libssl/src/crypto/x509v3/v3_pci.c b/src/lib/libssl/src/crypto/x509v3/v3_pci.c index d3f73352d9..d19f5a6e61 100644 --- a/src/lib/libssl/src/crypto/x509v3/v3_pci.c +++ b/src/lib/libssl/src/crypto/x509v3/v3_pci.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: v3_pci.c,v 1.8 2014/07/11 08:44:49 jsing Exp $ */ | 1 | /* $OpenBSD: v3_pci.c,v 1.9 2015/07/19 01:20:32 doug Exp $ */ | 
| 2 | /* Contributed to the OpenSSL Project 2004 | 2 | /* Contributed to the OpenSSL Project 2004 | 
| 3 | * by Richard Levitte (richard@levitte.org) | 3 | * by Richard Levitte (richard@levitte.org) | 
| 4 | */ | 4 | */ | 
| @@ -317,10 +317,6 @@ err: | |||
| 317 | ASN1_OCTET_STRING_free(policy); | 317 | ASN1_OCTET_STRING_free(policy); | 
| 318 | policy = NULL; | 318 | policy = NULL; | 
| 319 | } | 319 | } | 
| 320 | if (pci) { | ||
| 321 | PROXY_CERT_INFO_EXTENSION_free(pci); | ||
| 322 | pci = NULL; | ||
| 323 | } | ||
| 324 | end: | 320 | end: | 
| 325 | sk_CONF_VALUE_pop_free(vals, X509V3_conf_free); | 321 | sk_CONF_VALUE_pop_free(vals, X509V3_conf_free); | 
| 326 | return pci; | 322 | return pci; | 
