Util/ASCII: add StringEqualsCaseASCII() overload with length

Replaces GLib's g_ascii_strncasecmp().
This commit is contained in:
Max Kellermann
2013-10-21 08:42:55 +02:00
parent 0e4d2e7277
commit 222dc8a239
6 changed files with 23 additions and 11 deletions

View File

@@ -19,12 +19,11 @@
#include "config.h"
#include "PcmResampleInternal.hxx"
#include "util/ASCII.hxx"
#include "util/Error.hxx"
#include "util/Domain.hxx"
#include "Log.hxx"
#include <glib.h>
#include <assert.h>
#include <stdlib.h>
#include <string.h>
@@ -54,7 +53,7 @@ lsr_parse_converter(const char *s)
if (name == nullptr)
break;
if (g_ascii_strncasecmp(s, name, length) == 0) {
if (StringEqualsCaseASCII(s, name, length)) {
lsr_converter = i;
return true;
}