Module: kamailio Branch: master Commit: 9ee189883549faffb21d3ae113dafd7ad95757af URL: https://github.com/kamailio/kamailio/commit/9ee189883549faffb21d3ae113dafd7a...
Author: Victor Seva linuxmaniac@torreviejawireless.org Committer: Victor Seva linuxmaniac@torreviejawireless.org Date: 2024-10-22T16:45:35+02:00
pipelimit: use core str comparison functions
---
Modified: src/modules/pipelimit/pl_ht.h
---
Diff: https://github.com/kamailio/kamailio/commit/9ee189883549faffb21d3ae113dafd7a... Patch: https://github.com/kamailio/kamailio/commit/9ee189883549faffb21d3ae113dafd7a...
---
diff --git a/src/modules/pipelimit/pl_ht.h b/src/modules/pipelimit/pl_ht.h index 8ee6568ea69..86eab1092dc 100644 --- a/src/modules/pipelimit/pl_ht.h +++ b/src/modules/pipelimit/pl_ht.h @@ -98,16 +98,6 @@ typedef struct str_map
extern str_map_t algo_names[];
-static inline int str_cmp(const str *a, const str *b) -{ - return !(a->len == b->len && !strncmp(a->s, b->s, a->len)); -} - -static inline int str_i_cmp(const str *a, const str *b) -{ - return !(a->len == b->len && !strncasecmp(a->s, b->s, a->len)); -} - /** * converts a mapped str to an int * \return 0 if found, -1 otherwise @@ -115,7 +105,7 @@ static inline int str_i_cmp(const str *a, const str *b) static inline int str_map_str(const str_map_t *map, const str *key, int *ret) { for(; map->str.s; map++) - if(!str_i_cmp(&map->str, key)) { + if(!str_strcasecmp(&map->str, key)) { *ret = map->id; return 0; }