Error when using newer version of ffmpeg:
Upon further investigation, this error comes from newer versions of
FFmpeg [1] as the packet read callback's expected return value on EOF
has been changed. This commit fixes the issue by updating the packet
read callback used to play videos with FFmpeg to return AVERROR_EOF on
EOF instead of 0 as seen in mpv [2].
[1] https://git.videolan.org/?p=ffmpeg.git;a=commitdiff;h=a606f27f4c610708fa96e35eed7b7537d3d8f712
[2] e9dc4ac86f