Skip to content

Commit 76aba42

Browse files
committed
Fix api signature
1 parent c07f73b commit 76aba42

4 files changed

Lines changed: 5 additions & 5 deletions

File tree

src/ssl.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11811,15 +11811,15 @@ int wolfSSL_set_compression(WOLFSSL* ssl)
1181111811
}
1181211812
#endif /* SESSION_CERTS && OPENSSL_EXTRA */
1181311813

11814-
WOLFSSL_X509_STORE* wolfSSL_CTX_get_cert_store(WOLFSSL_CTX* ctx)
11814+
WOLFSSL_X509_STORE* wolfSSL_CTX_get_cert_store(const WOLFSSL_CTX* ctx)
1181511815
{
1181611816
if (ctx == NULL) {
1181711817
return NULL;
1181811818
}
1181911819

1182011820
if (ctx->x509_store_pt != NULL)
1182111821
return ctx->x509_store_pt;
11822-
return &ctx->x509_store;
11822+
return &((WOLFSSL_CTX*)ctx)->x509_store;
1182311823
}
1182411824

1182511825
void wolfSSL_CTX_set_cert_store(WOLFSSL_CTX* ctx, WOLFSSL_X509_STORE* str)

wolfssl/openssl/ssl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -931,7 +931,7 @@ wolfSSL_X509_STORE_set_verify_cb((WOLFSSL_X509_STORE *)(s), (WOLFSSL_X509_STORE_
931931
#endif
932932
#define SSL_set0_verify_cert_store wolfSSL_set0_verify_cert_store
933933
#define SSL_set1_verify_cert_store wolfSSL_set1_verify_cert_store
934-
#define SSL_CTX_get_cert_store(x) wolfSSL_CTX_get_cert_store ((WOLFSSL_CTX*) (x))
934+
#define SSL_CTX_get_cert_store(x) wolfSSL_CTX_get_cert_store ((x))
935935
#define SSL_get_client_CA_list wolfSSL_get_client_CA_list
936936
#define SSL_set_client_CA_list wolfSSL_set_client_CA_list
937937
#define SSL_get_ex_data_X509_STORE_CTX_idx wolfSSL_get_ex_data_X509_STORE_CTX_idx

wolfssl/openssl/x509v3.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ WOLFSSL_API WOLFSSL_ASN1_STRING* wolfSSL_a2i_IPADDRESS(const char* ipa);
145145

146146
#define BASIC_CONSTRAINTS_free wolfSSL_BASIC_CONSTRAINTS_free
147147
#define AUTHORITY_KEYID_free wolfSSL_AUTHORITY_KEYID_free
148-
#define SSL_CTX_get_cert_store(x) wolfSSL_CTX_get_cert_store ((WOLFSSL_CTX*) (x))
148+
#define SSL_CTX_get_cert_store(x) wolfSSL_CTX_get_cert_store ((x))
149149
#define ASN1_INTEGER WOLFSSL_ASN1_INTEGER
150150
#define ASN1_OCTET_STRING WOLFSSL_ASN1_STRING
151151
#define X509V3_EXT_get wolfSSL_X509V3_EXT_get

wolfssl/ssl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4493,7 +4493,7 @@ WOLFSSL_API int wolfSSL_set0_verify_cert_store(WOLFSSL *ssl,
44934493
WOLFSSL_X509_STORE* str);
44944494
WOLFSSL_API int wolfSSL_set1_verify_cert_store(WOLFSSL *ssl,
44954495
WOLFSSL_X509_STORE* str);
4496-
WOLFSSL_API WOLFSSL_X509_STORE* wolfSSL_CTX_get_cert_store(WOLFSSL_CTX* ctx);
4496+
WOLFSSL_API WOLFSSL_X509_STORE* wolfSSL_CTX_get_cert_store(const WOLFSSL_CTX* ctx);
44974497
#endif /* OPENSSL_EXTRA || WOLFSSL_WPAS_SMALL */
44984498
#if defined(OPENSSL_EXTRA) || defined(WOLFSSL_WPAS_SMALL) || \
44994499
defined(HAVE_SECRET_CALLBACK)

0 commit comments

Comments
 (0)