Browse Source

avformat/wavdec: make start_code string larger

av_get_codec_tag_string() uses more that 1 char for unprintable characters.
tags/n2.6
Clément Bœsch 11 years ago
parent
commit
83b0fe395b
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      libavformat/wavdec.c

+ 2
- 2
libavformat/wavdec.c View File

@@ -249,7 +249,7 @@ static int wav_read_header(AVFormatContext *s)
int64_t size, av_uninit(data_size);
int64_t sample_count = 0;
int rf64 = 0;
char start_code[5];
char start_code[32];
uint32_t tag;
AVIOContext *pb = s->pb;
AVStream *st = NULL;
@@ -273,7 +273,7 @@ static int wav_read_header(AVFormatContext *s)
rf64 = 1;
break;
default:
av_get_codec_tag_string(start_code, 5, tag);
av_get_codec_tag_string(start_code, sizeof(start_code), tag);
av_log(s, AV_LOG_ERROR, "invalid start code %s in RIFF header\n", start_code);
return AVERROR_INVALIDDATA;
}


Loading…
Cancel
Save