Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBaptiste Coudurier <baptiste.coudurier@gmail.com>2009-02-12 05:17:16 +0300
committerBaptiste Coudurier <baptiste.coudurier@gmail.com>2009-02-12 05:17:16 +0300
commit2dc91884652aa586951026dc2d518b9b6957577a (patch)
treed0a5f975865b932283afcf2b510c405e6227c44e /libavformat/ffmdec.c
parent6fcce4f995df3c6c44b16a810b772f529e9aa6bf (diff)
return error if read failed
Originally committed as revision 17173 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/ffmdec.c')
-rw-r--r--libavformat/ffmdec.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/ffmdec.c b/libavformat/ffmdec.c
index 6f96c719ab..e8e1891b4a 100644
--- a/libavformat/ffmdec.c
+++ b/libavformat/ffmdec.c
@@ -30,7 +30,8 @@ int64_t ffm_read_write_index(int fd)
uint8_t buf[8];
lseek(fd, 8, SEEK_SET);
- read(fd, buf, 8);
+ if (read(fd, buf, 8) != 8)
+ return AVERROR(EIO);
return AV_RB64(buf);
}