summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2018-02-21 17:02:18 +0100
committerKevin Mitchell <kevmitch@gmail.com>2018-02-21 22:57:39 -0800
commitfc76d41194813754fb687189a312f564c941e5fa (patch)
tree3e4f93a4fc3c02960120ea92e366c32bd6184d57 /video
parent4527409c8d968564de53e4dcf4021ff3ae2843b5 (diff)
downloadmpv-fc76d41194813754fb687189a312f564c941e5fa.tar.bz2
mpv-fc76d41194813754fb687189a312f564c941e5fa.tar.xz
stream_file: add mode for reading appended files
Do this because retrying reading on higher levels (like the demuxer) usually causes tons of problems. A hack like this is simpler and could allow to remove some of the higher level retry behavior. This works by trying to detect whether the file is appended. If we reach EOF, check if the file size changed compared to the initial value. If it did, it means the file was appended at least once, and we set the p->appending flag. If that flag is set, we simply retry reading more data every time we encounter EOF. The only way to do this is polling, and we poll for at most 10 times, after waiting for 200ms every time.
Diffstat (limited to 'video')
0 files changed, 0 insertions, 0 deletions