summaryrefslogtreecommitdiffstats
path: root/crypto/property/defn_cache.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/property/defn_cache.c')
-rw-r--r--crypto/property/defn_cache.c17
1 files changed, 5 insertions, 12 deletions
diff --git a/crypto/property/defn_cache.c b/crypto/property/defn_cache.c
index b4cd67c990..c697e6f474 100644
--- a/crypto/property/defn_cache.c
+++ b/crypto/property/defn_cache.c
@@ -15,6 +15,7 @@
#include "internal/property.h"
#include "internal/core.h"
#include "property_local.h"
+#include "crypto/context.h"
/*
* Implement a property definition cache.
@@ -47,7 +48,7 @@ static void property_defn_free(PROPERTY_DEFN_ELEM *elem)
OPENSSL_free(elem);
}
-static void property_defns_free(void *vproperty_defns)
+void ossl_property_defns_free(void *vproperty_defns)
{
LHASH_OF(PROPERTY_DEFN_ELEM) *property_defns = vproperty_defns;
@@ -58,24 +59,17 @@ static void property_defns_free(void *vproperty_defns)
}
}
-static void *property_defns_new(OSSL_LIB_CTX *ctx) {
+void *ossl_property_defns_new(OSSL_LIB_CTX *ctx) {
return lh_PROPERTY_DEFN_ELEM_new(&property_defn_hash, &property_defn_cmp);
}
-static const OSSL_LIB_CTX_METHOD property_defns_method = {
- OSSL_LIB_CTX_METHOD_DEFAULT_PRIORITY,
- property_defns_new,
- property_defns_free,
-};
-
OSSL_PROPERTY_LIST *ossl_prop_defn_get(OSSL_LIB_CTX *ctx, const char *prop)
{
PROPERTY_DEFN_ELEM elem, *r;
LHASH_OF(PROPERTY_DEFN_ELEM) *property_defns;
property_defns = ossl_lib_ctx_get_data(ctx,
- OSSL_LIB_CTX_PROPERTY_DEFN_INDEX,
- &property_defns_method);
+ OSSL_LIB_CTX_PROPERTY_DEFN_INDEX);
if (property_defns == NULL || !ossl_lib_ctx_read_lock(ctx))
return NULL;
@@ -99,8 +93,7 @@ int ossl_prop_defn_set(OSSL_LIB_CTX *ctx, const char *prop,
int res = 1;
property_defns = ossl_lib_ctx_get_data(ctx,
- OSSL_LIB_CTX_PROPERTY_DEFN_INDEX,
- &property_defns_method);
+ OSSL_LIB_CTX_PROPERTY_DEFN_INDEX);
if (property_defns == NULL)
return 0;