$OpenBSD: patch-qca-tls_cpp,v 1.2 2010/10/06 18:44:58 kili Exp $
--- qca-tls.cpp.orig	Wed Dec 10 17:53:57 2003
+++ qca-tls.cpp	Mon Oct  4 18:56:39 2010
@@ -454,7 +454,11 @@ class RSAKeyContext : public QCA_RSAKeyContext (public
 			if(!r) {
 				// try this other public function, for whatever reason
 				p = (void *)in;
+#ifdef OSSL_098
+				r = d2i_RSA_PUBKEY(NULL, (const unsigned char **)&p, len);
+#else
 				r = d2i_RSA_PUBKEY(NULL, (unsigned char **)&p, len);
+#endif
 			}
 			if(r) {
 				if(pub) {
@@ -799,7 +803,11 @@ class CertContext : public QCA_CertContext (public)
 	bool createFromDER(const char *in, unsigned int len)
 	{
 		unsigned char *p = (unsigned char *)in;
+#ifdef OSSL_098
+		X509 *t = d2i_X509(NULL, (const unsigned char**)&p, len);
+#else
 		X509 *t = d2i_X509(NULL, &p, len);
+#endif
 		if(!t)
 			return false;
 		fromX509(t);
@@ -945,7 +953,7 @@ class TLSContext : public QCA_TLSContext (public)
 	RSAKeyContext *key;
 
 	SSL *ssl;
-	SSL_METHOD *method;
+	const SSL_METHOD *method;
 	SSL_CTX *context;
 	BIO *rbio, *wbio;
 	CertContext cc;
