You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
507 B

  1. --- a/src/decoder/FfmpegDecoderPlugin.cxx
  2. +++ b/src/decoder/FfmpegDecoderPlugin.cxx
  3. @@ -376,6 +376,13 @@ ffmpeg_probe(Decoder *decoder, InputStre
  4. unsigned char buffer[BUFFER_SIZE];
  5. size_t nbytes = decoder_read(decoder, is, buffer, BUFFER_SIZE);
  6. +
  7. + if ((nbytes > 0) && (nbytes < 1024))
  8. + {
  9. + // Gobble some more data if header is small
  10. + nbytes += decoder_read(decoder, is, buffer + nbytes, BUFFER_SIZE - nbytes);
  11. + }
  12. +
  13. if (nbytes <= PADDING || !is.LockRewind(IgnoreError()))
  14. return nullptr;