mirror of
https://github.com/mpv-player/mpv
synced 2025-03-23 03:37:27 +00:00
demux_libarchive: reject 0-sized files
libarchive does strange things with them.
This commit is contained in:
parent
cf2fa9d3e5
commit
da8a9ff589
@ -32,6 +32,9 @@ static int cmp_filename(const void *a, const void *b)
|
||||
|
||||
static int open_file(struct demuxer *demuxer, enum demux_check check)
|
||||
{
|
||||
if (stream_get_size(demuxer->stream) == 0)
|
||||
return -1;
|
||||
|
||||
int flags = 0;
|
||||
if (check <= DEMUX_CHECK_REQUEST)
|
||||
flags |= MP_ARCHIVE_FLAG_UNSAFE;
|
||||
|
Loading…
Reference in New Issue
Block a user