aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-10-02 07:27:08 +0000
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-10-02 07:27:08 +0000
commit3fcb5113c6933fd5db55917ecdd54ee6556b0a93 (patch)
tree33f51f06fbc7ad0fcf9d0e25b53eb8947cc0ec14
parente581b6288f7c8c356593842c172cf867ca4177d6 (diff)
downloadffmpeg-3fcb5113c6933fd5db55917ecdd54ee6556b0a93.tar.gz
wav demuxer: return AVERROR_EOF instead of AVERROR(EIO) when the end of
the file is reached normally, without any error. Originally committed as revision 20143 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r--libavformat/wav.c2
-rw-r--r--tests/seek.regression.ref24
2 files changed, 13 insertions, 13 deletions
diff --git a/libavformat/wav.c b/libavformat/wav.c
index e1ad08ea9a..1ac1e64517 100644
--- a/libavformat/wav.c
+++ b/libavformat/wav.c
@@ -256,7 +256,7 @@ static int wav_read_packet(AVFormatContext *s,
else
left = find_tag(s->pb, MKTAG('d', 'a', 't', 'a'));
if (left < 0)
- return AVERROR(EIO);
+ return AVERROR_EOF;
wav->data_end= url_ftell(s->pb) + left;
}
diff --git a/tests/seek.regression.ref b/tests/seek.regression.ref
index d523774431..d88496c537 100644
--- a/tests/seek.regression.ref
+++ b/tests/seek.regression.ref
@@ -3740,51 +3740,51 @@ ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st:-1 ts:-1.000000 flags:0
ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st:-1 ts:1.894167 flags:1
-ret:-5
+ret:-32
ret: 0 st: 0 ts:0.788345 flags:0
ret: 0 st: 0 dts:0.788345 pts:0.788345 pos:69576 size:4096 flags:1
ret: 0 st: 0 ts:-0.317506 flags:1
ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st:-1 ts:2.576668 flags:0
-ret:-5
+ret:-32
ret: 0 st:-1 ts:1.470835 flags:1
-ret:-5
+ret:-32
ret: 0 st: 0 ts:0.365011 flags:0
ret: 0 st: 0 dts:0.365011 pts:0.365011 pos:32238 size:4096 flags:1
ret: 0 st: 0 ts:-0.740839 flags:1
ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st:-1 ts:2.153336 flags:0
-ret:-5
+ret:-32
ret: 0 st:-1 ts:1.047503 flags:1
-ret:-5
+ret:-32
ret: 0 st: 0 ts:-0.058322 flags:0
ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st: 0 ts:2.835828 flags:1
-ret:-5
+ret:-32
ret: 0 st:-1 ts:1.730004 flags:0
-ret:-5
+ret:-32
ret: 0 st:-1 ts:0.624171 flags:1
ret: 0 st: 0 dts:0.624172 pts:0.624172 pos:55096 size:4096 flags:1
ret: 0 st: 0 ts:-0.481655 flags:0
ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st: 0 ts:2.412494 flags:1
-ret:-5
+ret:-32
ret: 0 st:-1 ts:1.306672 flags:0
-ret:-5
+ret:-32
ret: 0 st:-1 ts:0.200839 flags:1
ret: 0 st: 0 dts:0.200839 pts:0.200839 pos:17758 size:4096 flags:1
ret: 0 st: 0 ts:-0.904989 flags:0
ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st: 0 ts:1.989184 flags:1
-ret:-5
+ret:-32
ret: 0 st:-1 ts:0.883340 flags:0
ret: 0 st: 0 dts:0.883333 pts:0.883333 pos:77954 size:4096 flags:1
ret: 0 st:-1 ts:-0.222493 flags:1
ret: 0 st: 0 dts:0.000000 pts:0.000000 pos:44 size:4096 flags:1
ret: 0 st: 0 ts:2.671678 flags:0
-ret:-5
+ret:-32
ret: 0 st: 0 ts:1.565850 flags:1
-ret:-5
+ret:-32
ret: 0 st:-1 ts:0.460008 flags:0
ret: 0 st: 0 dts:0.460000 pts:0.460000 pos:40616 size:4096 flags:1
ret: 0 st:-1 ts:-0.645825 flags:1