aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRenĂ© Korthaus <[email protected]>2016-09-04 18:27:40 +0200
committerRenĂ© Korthaus <[email protected]>2016-09-04 18:27:40 +0200
commit2a6645370d45f850351e6003bd5adc06924520c4 (patch)
tree40f2667f1a1f8839cf1256d93da95a180bd46e8f /src
parent2985b74307d7a8533700be7b0bc354fb4968b7d6 (diff)
Call base class assignment operator in X509_Certificate
Diffstat (limited to 'src')
-rw-r--r--src/lib/cert/x509/x509cert.cpp1
-rw-r--r--src/tests/unit_x509.cpp4
2 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/cert/x509/x509cert.cpp b/src/lib/cert/x509/x509cert.cpp
index ffedf43f0..4d9482e93 100644
--- a/src/lib/cert/x509/x509cert.cpp
+++ b/src/lib/cert/x509/x509cert.cpp
@@ -89,6 +89,7 @@ X509_Certificate& X509_Certificate::operator=(const X509_Certificate& other)
}
else
{
+ X509_Object::operator=(other);
m_subject = other.m_subject;
m_issuer = other.m_issuer;
m_self_signed = other.m_self_signed;
diff --git a/src/tests/unit_x509.cpp b/src/tests/unit_x509.cpp
index 4d3c63a1b..8449beba4 100644
--- a/src/tests/unit_x509.cpp
+++ b/src/tests/unit_x509.cpp
@@ -308,8 +308,8 @@ Test::Result test_x509_cert(const std::string& sig_algo, const std::string& hash
Botan::X509_Certificate user1_cert_copy(user1_cert);
result.test_eq("certificate copy", user1_cert == user1_cert_copy, true);
- user1_cert_copy = user1_cert;
- result.test_eq("certificate assignment", user1_cert == user1_cert_copy, true);
+ user1_cert_copy = user2_cert;
+ result.test_eq("certificate assignment", user2_cert == user1_cert_copy, true);
Botan::X509_Certificate user1_cert_differ =
ca.sign_request(user1_req, Test::rng(),