summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/engine/eng_lib.c
diff options
context:
space:
mode:
authorbeck <>2014-04-17 13:37:50 +0000
committerbeck <>2014-04-17 13:37:50 +0000
commitbddb7c686e3d1aeb156722adc64b6c35ae720f87 (patch)
tree7595a93a27385c367802aa17ecf20f96551cf14d /src/lib/libcrypto/engine/eng_lib.c
parentecec66222d758996a4ff2671ca5026d9ede5ef76 (diff)
downloadopenbsd-bddb7c686e3d1aeb156722adc64b6c35ae720f87.tar.gz
openbsd-bddb7c686e3d1aeb156722adc64b6c35ae720f87.tar.bz2
openbsd-bddb7c686e3d1aeb156722adc64b6c35ae720f87.zip
Change library to use intrinsic memory allocation functions instead of
OPENSSL_foo wrappers. This changes: OPENSSL_malloc->malloc OPENSSL_free->free OPENSSL_relloc->realloc OPENSSL_freeFunc->free
Diffstat (limited to 'src/lib/libcrypto/engine/eng_lib.c')
-rw-r--r--src/lib/libcrypto/engine/eng_lib.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/libcrypto/engine/eng_lib.c b/src/lib/libcrypto/engine/eng_lib.c
index 18a6664645..126bc02296 100644
--- a/src/lib/libcrypto/engine/eng_lib.c
+++ b/src/lib/libcrypto/engine/eng_lib.c
@@ -65,7 +65,7 @@ ENGINE *ENGINE_new(void)
65 { 65 {
66 ENGINE *ret; 66 ENGINE *ret;
67 67
68 ret = (ENGINE *)OPENSSL_malloc(sizeof(ENGINE)); 68 ret = (ENGINE *)malloc(sizeof(ENGINE));
69 if(ret == NULL) 69 if(ret == NULL)
70 { 70 {
71 ENGINEerr(ENGINE_F_ENGINE_NEW, ERR_R_MALLOC_FAILURE); 71 ENGINEerr(ENGINE_F_ENGINE_NEW, ERR_R_MALLOC_FAILURE);
@@ -133,7 +133,7 @@ int engine_free_util(ENGINE *e, int locked)
133 if(e->destroy) 133 if(e->destroy)
134 e->destroy(e); 134 e->destroy(e);
135 CRYPTO_free_ex_data(CRYPTO_EX_INDEX_ENGINE, e, &e->ex_data); 135 CRYPTO_free_ex_data(CRYPTO_EX_INDEX_ENGINE, e, &e->ex_data);
136 OPENSSL_free(e); 136 free(e);
137 return 1; 137 return 1;
138 } 138 }
139 139
@@ -158,7 +158,7 @@ static int int_cleanup_check(int create)
158 } 158 }
159static ENGINE_CLEANUP_ITEM *int_cleanup_item(ENGINE_CLEANUP_CB *cb) 159static ENGINE_CLEANUP_ITEM *int_cleanup_item(ENGINE_CLEANUP_CB *cb)
160 { 160 {
161 ENGINE_CLEANUP_ITEM *item = OPENSSL_malloc(sizeof( 161 ENGINE_CLEANUP_ITEM *item = malloc(sizeof(
162 ENGINE_CLEANUP_ITEM)); 162 ENGINE_CLEANUP_ITEM));
163 if(!item) return NULL; 163 if(!item) return NULL;
164 item->cb = cb; 164 item->cb = cb;
@@ -184,7 +184,7 @@ void engine_cleanup_add_last(ENGINE_CLEANUP_CB *cb)
184static void engine_cleanup_cb_free(ENGINE_CLEANUP_ITEM *item) 184static void engine_cleanup_cb_free(ENGINE_CLEANUP_ITEM *item)
185 { 185 {
186 (*(item->cb))(); 186 (*(item->cb))();
187 OPENSSL_free(item); 187 free(item);
188 } 188 }
189void ENGINE_cleanup(void) 189void ENGINE_cleanup(void)
190 { 190 {