Skip to content

Commit

Permalink
lavf/rpl: Don't be case-sensitive detecting codecs.
Browse files Browse the repository at this point in the history
Fixes ticket #7859
Reported and tested by Steffen Ohrendorf, steffen d ohrendorf a gmx d de
  • Loading branch information
cehoyos committed May 5, 2019
1 parent 328a968 commit 8cf5f94
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libavformat/rpl.c
Original file line number Diff line number Diff line change
Expand Up @@ -210,10 +210,10 @@ static int rpl_read_header(AVFormatContext *s)
ast->codecpar->codec_id = AV_CODEC_ID_PCM_S16LE;
break;
} else if (ast->codecpar->bits_per_coded_sample == 8) {
if(strstr(audio_type, "unsigned") != NULL) {
if(av_strcasecmp(audio_type, "unsigned") >= 0) {
ast->codecpar->codec_id = AV_CODEC_ID_PCM_U8;
break;
} else if(strstr(audio_type, "linear") != NULL) {
} else if(av_strcasecmp(audio_type, "linear") >= 0) {
ast->codecpar->codec_id = AV_CODEC_ID_PCM_S8;
break;
} else {
Expand Down

0 comments on commit 8cf5f94

Please sign in to comment.