diff options
author | Dmitry Belyavskiy <beldmit@gmail.com> | 2022-04-12 12:30:08 +0200 |
---|---|---|
committer | Dmitry Belyavskiy <beldmit@gmail.com> | 2022-04-21 17:12:32 +0200 |
commit | 2c31d942af28a20e87979cbc76c3dd8d162c1a9c (patch) | |
tree | a7927f89d19ef4c9604eb80fbefc4fa1ac2d4734 /crypto/objects | |
parent | a8e4ddc6d15b6e6b308428753bc22b12422adacf (diff) | |
download | openssl-2c31d942af28a20e87979cbc76c3dd8d162c1a9c.zip openssl-2c31d942af28a20e87979cbc76c3dd8d162c1a9c.tar.gz openssl-2c31d942af28a20e87979cbc76c3dd8d162c1a9c.tar.bz2 |
str[n]casecmp => OPENSSL_strncasecmp
Reviewed-by: Tim Hudson <tjh@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18103)
Diffstat (limited to 'crypto/objects')
-rw-r--r-- | crypto/objects/o_names.c | 21 |
1 files changed, 2 insertions, 19 deletions
diff --git a/crypto/objects/o_names.c b/crypto/objects/o_names.c index 92152ee..7596d72 100644 --- a/crypto/objects/o_names.c +++ b/crypto/objects/o_names.c @@ -22,23 +22,6 @@ #include "e_os.h" /* - * We define this wrapper for two reasons. Firstly, later versions of - * DEC C add linkage information to certain functions, which makes it - * tricky to use them as values to regular function pointers. - * Secondly, in the EDK2 build environment, the strcasecmp function is - * actually an external function with the Microsoft ABI, so we can't - * transparently assign function pointers to it. - */ -#if defined(OPENSSL_SYS_VMS_DECC) || defined(OPENSSL_SYS_UEFI) -static int obj_strcasecmp(const char *a, const char *b) -{ - return strcasecmp(a, b); -} -#else -#define obj_strcasecmp strcasecmp -#endif - -/* * I use the ex_data stuff to manage the identifiers for the obj_name_types * that applications may define. I only really use the free function field. */ @@ -111,7 +94,7 @@ int OBJ_NAME_new_index(unsigned long (*hash_func) (const char *), goto out; } name_funcs->hash_func = ossl_lh_strcasehash; - name_funcs->cmp_func = obj_strcasecmp; + name_funcs->cmp_func = OPENSSL_strcasecmp; push = sk_NAME_FUNCS_push(name_funcs_stack, name_funcs); if (!push) { @@ -145,7 +128,7 @@ static int obj_name_cmp(const OBJ_NAME *a, const OBJ_NAME *b) ret = sk_NAME_FUNCS_value(name_funcs_stack, a->type)->cmp_func(a->name, b->name); } else - ret = strcasecmp(a->name, b->name); + ret = OPENSSL_strcasecmp(a->name, b->name); } return ret; } |