git.videolan.org
/
ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9bb6e11
)
avformat/mp3dec: avoid seeking to negative positions
author
Michael Niedermayer
<michaelni@gmx.at>
Tue, 18 Nov 2014 03:04:37 +0000
(
04:04
+0100)
committer
Michael Niedermayer
<michaelni@gmx.at>
Tue, 18 Nov 2014 03:04:37 +0000
(
04:04
+0100)
Fixes Ticket4038
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/mp3dec.c
patch
|
blob
|
history
diff --git
a/libavformat/mp3dec.c
b/libavformat/mp3dec.c
index
8208dbb
..
c4c1bb7
100644
(file)
--- a/
libavformat/mp3dec.c
+++ b/
libavformat/mp3dec.c
@@
-457,6
+457,10
@@
static int mp3_seek(AVFormatContext *s, int stream_index, int64_t timestamp,
int64_t pos = ie->pos + (dir > 0 ? i - 1024 : -i);
int64_t candidate = -1;
int score = 999;
+
+ if (pos < 0)
+ continue;
+
for(j=0; j<MIN_VALID; j++) {
ret = check(s, pos);
if(ret < 0)