oss_mixer: use g_ascii_strncasecmp() instead of strncasecmp()
strncasecmp() is locale dependent, but we only need ASCII here.
This commit is contained in:
parent
114d5982bb
commit
dd8c6d6738
@ -88,7 +88,7 @@ oss_find_mixer(const char *name)
|
|||||||
size_t name_length = strlen(name);
|
size_t name_length = strlen(name);
|
||||||
|
|
||||||
for (unsigned i = 0; i < SOUND_MIXER_NRDEVICES; i++) {
|
for (unsigned i = 0; i < SOUND_MIXER_NRDEVICES; i++) {
|
||||||
if (strncasecmp(name, labels[i], name_length) == 0 &&
|
if (g_ascii_strncasecmp(name, labels[i], name_length) == 0 &&
|
||||||
(labels[i][name_length] == 0 ||
|
(labels[i][name_length] == 0 ||
|
||||||
labels[i][name_length] == ' '))
|
labels[i][name_length] == ' '))
|
||||||
return i;
|
return i;
|
||||||
|
Loading…
Reference in New Issue
Block a user