diff options
author | wm4 <wm4@nowhere> | 2017-12-23 21:18:13 +0100 |
---|---|---|
committer | Kevin Mitchell <kevmitch@gmail.com> | 2017-12-23 15:14:13 -0700 |
commit | a721dac6012d33b3ab2650a7ead69d87a980bcc1 (patch) | |
tree | 2fc9f554aada815f24f365d7cd37c8e820c82bcd /player/loadfile.c | |
parent | 30686dcec3c6b83fd15a741ae972bf491731abc0 (diff) | |
download | mpv-a721dac6012d33b3ab2650a7ead69d87a980bcc1.tar.bz2 mpv-a721dac6012d33b3ab2650a7ead69d87a980bcc1.tar.xz |
player: make track language matching case insensitive
There is no reason not to do this, and probably saves the user some
trouble.
Mostly untested.
Closes #5272.
Diffstat (limited to 'player/loadfile.c')
-rw-r--r-- | player/loadfile.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/player/loadfile.c b/player/loadfile.c index ff401cd590..8139c06f3f 100644 --- a/player/loadfile.c +++ b/player/loadfile.c @@ -296,7 +296,7 @@ void add_demuxer_tracks(struct MPContext *mpctx, struct demuxer *demuxer) static int match_lang(char **langs, char *lang) { for (int idx = 0; langs && langs[idx]; idx++) { - if (lang && strcmp(langs[idx], lang) == 0) + if (lang && strcasecmp(langs[idx], lang) == 0) return INT_MAX - idx; } return 0; |