From a8ffb15c4a0566fabb50c94524e881ba2036dd1a Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 11 Aug 2021 23:28:18 -0400 Subject: Expose serd_strncasecmp in public API --- include/serd/serd.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'include/serd') diff --git a/include/serd/serd.h b/include/serd/serd.h index f30026ca..96890dbd 100644 --- a/include/serd/serd.h +++ b/include/serd/serd.h @@ -292,6 +292,18 @@ SERD_API char* SERD_NULLABLE serd_canonical_path(const char* SERD_NONNULL path); +/** + Compare two strings ignoring case. + + @return Less than, equal to, or greater than zero if `s1` is less than, + equal to, or greater than `s2`, respectively. +*/ +SERD_PURE_API +int +serd_strncasecmp(const char* SERD_NONNULL s1, + const char* SERD_NONNULL s2, + size_t n); + /** @} @defgroup serd_io_functions I/O Function Types -- cgit v1.2.1