More compatibility fixes for older ffmpeg.