diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2009-06-30 11:21:00 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2009-06-30 11:21:00 +0000 |
commit | 43ea53a04a241785357e2d06869e94264fdac712 (patch) | |
tree | e18a66401f3f91fe89e6897a6809a0835175ad6f /crypto/x509 | |
parent | fa07f00aafb043db93a412061e1da1bb18b195e8 (diff) |
Inherit parameters properly in SSL contexts: any parameters set should
replace those in the current list.
Diffstat (limited to 'crypto/x509')
-rw-r--r-- | crypto/x509/x509_vpm.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/crypto/x509/x509_vpm.c b/crypto/x509/x509_vpm.c index acc50f97d5..dfd89d89fa 100644 --- a/crypto/x509/x509_vpm.c +++ b/crypto/x509/x509_vpm.c @@ -199,8 +199,12 @@ int X509_VERIFY_PARAM_inherit(X509_VERIFY_PARAM *dest, int X509_VERIFY_PARAM_set1(X509_VERIFY_PARAM *to, const X509_VERIFY_PARAM *from) { + unsigned long save_flags = to->inh_flags; + int ret; to->inh_flags |= X509_VP_FLAG_DEFAULT; - return X509_VERIFY_PARAM_inherit(to, from); + ret = X509_VERIFY_PARAM_inherit(to, from); + to->inh_flags = save_flags; + return ret; } int X509_VERIFY_PARAM_set1_name(X509_VERIFY_PARAM *param, const char *name) |