summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/objects/o_names.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/objects/o_names.c')
-rw-r--r--src/lib/libcrypto/objects/o_names.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/lib/libcrypto/objects/o_names.c b/src/lib/libcrypto/objects/o_names.c
index 2cdd2f3aa6..48b95d6767 100644
--- a/src/lib/libcrypto/objects/o_names.c
+++ b/src/lib/libcrypto/objects/o_names.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: o_names.c,v 1.23 2022/11/08 23:19:09 mbuhl Exp $ */ 1/* $OpenBSD: o_names.c,v 1.24 2023/07/08 12:27:51 beck Exp $ */
2#include <stdio.h> 2#include <stdio.h>
3#include <stdlib.h> 3#include <stdlib.h>
4#include <string.h> 4#include <string.h>
@@ -47,6 +47,7 @@ OBJ_NAME_init(void)
47 names_lh = lh_OBJ_NAME_new(); 47 names_lh = lh_OBJ_NAME_new();
48 return (names_lh != NULL); 48 return (names_lh != NULL);
49} 49}
50LCRYPTO_ALIAS(OBJ_NAME_init);
50 51
51int 52int
52OBJ_NAME_new_index(unsigned long (*hash_func)(const char *), 53OBJ_NAME_new_index(unsigned long (*hash_func)(const char *),
@@ -88,6 +89,7 @@ OBJ_NAME_new_index(unsigned long (*hash_func)(const char *),
88 name_funcs->free_func = free_func; 89 name_funcs->free_func = free_func;
89 return (ret); 90 return (ret);
90} 91}
92LCRYPTO_ALIAS(OBJ_NAME_new_index);
91 93
92/* static int obj_name_cmp(OBJ_NAME *a, OBJ_NAME *b) */ 94/* static int obj_name_cmp(OBJ_NAME *a, OBJ_NAME *b) */
93static int 95static int
@@ -157,6 +159,7 @@ OBJ_NAME_get(const char *name, int type)
157 } 159 }
158 } 160 }
159} 161}
162LCRYPTO_ALIAS(OBJ_NAME_get);
160 163
161int 164int
162OBJ_NAME_add(const char *name, int type, const char *data) 165OBJ_NAME_add(const char *name, int type, const char *data)
@@ -204,6 +207,7 @@ OBJ_NAME_add(const char *name, int type, const char *data)
204 } 207 }
205 return (1); 208 return (1);
206} 209}
210LCRYPTO_ALIAS(OBJ_NAME_add);
207 211
208int 212int
209OBJ_NAME_remove(const char *name, int type) 213OBJ_NAME_remove(const char *name, int type)
@@ -234,6 +238,7 @@ OBJ_NAME_remove(const char *name, int type)
234 } else 238 } else
235 return (0); 239 return (0);
236} 240}
241LCRYPTO_ALIAS(OBJ_NAME_remove);
237 242
238struct doall { 243struct doall {
239 int type; 244 int type;
@@ -262,6 +267,7 @@ OBJ_NAME_do_all(int type, void (*fn)(const OBJ_NAME *, void *arg), void *arg)
262 lh_OBJ_NAME_doall_arg(names_lh, LHASH_DOALL_ARG_FN(do_all_fn), 267 lh_OBJ_NAME_doall_arg(names_lh, LHASH_DOALL_ARG_FN(do_all_fn),
263 struct doall, &d); 268 struct doall, &d);
264} 269}
270LCRYPTO_ALIAS(OBJ_NAME_do_all);
265 271
266struct doall_sorted { 272struct doall_sorted {
267 int type; 273 int type;
@@ -311,6 +317,7 @@ OBJ_NAME_do_all_sorted(int type, void (*fn)(const OBJ_NAME *, void *arg),
311 free(d.names); 317 free(d.names);
312 } 318 }
313} 319}
320LCRYPTO_ALIAS(OBJ_NAME_do_all_sorted);
314 321
315static int free_type; 322static int free_type;
316 323
@@ -353,3 +360,4 @@ OBJ_NAME_cleanup(int type)
353 } else 360 } else
354 lh_OBJ_NAME_down_load(names_lh) = down_load; 361 lh_OBJ_NAME_down_load(names_lh) = down_load;
355} 362}
363LCRYPTO_ALIAS(OBJ_NAME_cleanup);