diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-01-13 22:14:02 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-02-04 05:20:07 +0100 |
commit | 82b44665e98256cd335ac35b4b6f1d46d82126cf (patch) | |
tree | b6bf2d03118fcff352805e642e778403d630083b | |
parent | 35bf91c5b55b43f699138c74618afc1f7815ee1c (diff) | |
download | ffmpeg-82b44665e98256cd335ac35b4b6f1d46d82126cf.tar.gz |
avformat/utils/av_probe_input_buffer2: Fix pd.buf_size
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 6a2064820b52568c05a9ec8f418f18840e7c43cc)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavformat/utils.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c index 9d1dad1807..3a736d18e0 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -482,7 +482,8 @@ int av_probe_input_buffer(AVIOContext *pb, AVInputFormat **fmt, score = 0; ret = 0; /* error was end of file, nothing read */ } - pd.buf_size = buf_offset += ret; + buf_offset += ret; + pd.buf_size = buf_offset - offset; pd.buf = &buf[offset]; memset(pd.buf + pd.buf_size, 0, AVPROBE_PADDING_SIZE); |