mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-20 06:11:04 +00:00
lavf/http: return error from seek on invalid whence
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
This commit is contained in:
parent
4ba6a534dc
commit
1aa262f460
@ -959,6 +959,8 @@ static int64_t http_seek(URLContext *h, int64_t off, int whence)
|
||||
off += s->off;
|
||||
else if (whence == SEEK_END)
|
||||
off += s->filesize;
|
||||
else if (whence != SEEK_SET)
|
||||
return AVERROR(EINVAL);
|
||||
if (off < 0)
|
||||
return AVERROR(EINVAL);
|
||||
s->off = off;
|
||||
|
Loading…
Reference in New Issue
Block a user