OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0ebb523
)
asfdec: short-circuit seeking to the start of stream
author
Andrew Kelley
<superjoe30@gmail.com>
Sun, 2 Feb 2014 23:05:58 +0000
(23:05 +0000)
committer
Janne Grunau
<janne-libav@jannau.net>
Wed, 12 Feb 2014 11:52:28 +0000
(12:52 +0100)
Bug-id: 43
Signed-off-by: Janne Grunau <janne-libav@jannau.net>
libavformat/asfdec.c
patch
|
blob
|
history
diff --git
a/libavformat/asfdec.c
b/libavformat/asfdec.c
index
e754cb2
..
8580ce0
100644
(file)
--- a/
libavformat/asfdec.c
+++ b/
libavformat/asfdec.c
@@
-1465,6
+1465,13
@@
static int asf_read_seek(AVFormatContext *s, int stream_index,
return ret;
}
+ /* explicitly handle the case of seeking to 0 */
+ if (!pts) {
+ asf_reset_header(s);
+ avio_seek(s->pb, s->data_offset, SEEK_SET);
+ return 0;
+ }
+
if (!asf->index_read)
ret = asf_build_simple_index(s, stream_index);