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:
ce739e6
)
cache: check lseek() return
author
Michael Niedermayer
<michaelni@gmx.at>
Wed, 17 Oct 2012 22:55:03 +0000
(
00:55
+0200)
committer
Michael Niedermayer
<michaelni@gmx.at>
Wed, 17 Oct 2012 22:55:03 +0000
(
00:55
+0200)
Fixes CID717496
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/cache.c
patch
|
blob
|
history
diff --git
a/libavformat/cache.c
b/libavformat/cache.c
index
2cfc396
..
35f81e8
100644
(file)
--- a/
libavformat/cache.c
+++ b/
libavformat/cache.c
@@
-114,7
+114,9
@@
static int64_t cache_seek(URLContext *h, int64_t pos, int whence)
c->pos= pos;
return pos;
}else{
- lseek(c->fd, c->pos, SEEK_SET);
+ if(lseek(c->fd, c->pos, SEEK_SET) < 0) {
+ av_log(h, AV_LOG_ERROR, "Failure to seek in cache\n");
+ }
return AVERROR(EPIPE);
}
}