summaryrefslogtreecommitdiffstats
path: root/tdeio/kssl/ksslpkcs12.cc
diff options
context:
space:
mode:
Diffstat (limited to 'tdeio/kssl/ksslpkcs12.cc')
-rw-r--r--tdeio/kssl/ksslpkcs12.cc29
1 files changed, 4 insertions, 25 deletions
diff --git a/tdeio/kssl/ksslpkcs12.cc b/tdeio/kssl/ksslpkcs12.cc
index 9521e907b..08bc54a0b 100644
--- a/tdeio/kssl/ksslpkcs12.cc
+++ b/tdeio/kssl/ksslpkcs12.cc
@@ -34,16 +34,6 @@
#include <assert.h>
-#ifdef KSSL_HAVE_SSL
-#define sk_new kossl->sk_new
-#define sk_push kossl->sk_push
-#define sk_free kossl->sk_free
-#define sk_value kossl->sk_value
-#define sk_num kossl->sk_num
-#define sk_dup kossl->sk_dup
-#define sk_pop kossl->sk_pop
-#endif
-
KSSLPKCS12::KSSLPKCS12() {
_pkcs = NULL;
@@ -60,11 +50,11 @@ KSSLPKCS12::~KSSLPKCS12() {
if (_pkey) kossl->EVP_PKEY_free(_pkey);
if (_caStack) {
for (;;) {
- X509* x5 = sk_X509_pop(_caStack);
+ X509* x5 = reinterpret_cast<X509*>(kossl->OPENSSL_sk_pop(_caStack));
if (!x5) break;
kossl->X509_free(x5);
}
- sk_X509_free(_caStack);
+ kossl->OPENSSL_sk_free(_caStack);
}
if (_pkcs) kossl->PKCS12_free(_pkcs);
#endif
@@ -151,11 +141,11 @@ X509 *x = NULL;
if (_pkey) kossl->EVP_PKEY_free(_pkey);
if (_caStack) {
for (;;) {
- X509* x5 = sk_X509_pop(_caStack);
+ X509* x5 = reinterpret_cast<X509*>(kossl->OPENSSL_sk_pop(_caStack));
if (!x5) break;
kossl->X509_free(x5);
}
- sk_X509_free(_caStack);
+ kossl->OPENSSL_sk_free(_caStack);
}
_pkey = NULL;
_caStack = NULL;
@@ -282,14 +272,3 @@ TQString KSSLPKCS12::name() {
return _cert->getSubject();
}
-
-#ifdef KSSL_HAVE_SSL
-#undef sk_new
-#undef sk_push
-#undef sk_free
-#undef sk_value
-#undef sk_num
-#undef sk_pop
-#undef sk_dup
-#endif
-