Opened 10 years ago
Closed 10 years ago
#3935 closed defect (fixed)
srtdec fails to probe files whose first event ID is not 1 or 0
Reported by: | Ridley Combs | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | avformat |
Version: | git-master | Keywords: | srt probe sub |
Cc: | Blocked By: | ||
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
Summary of the bug:
Some SRT files in the wild don't start with 0 or 1. These files are currently not probed by srtdec, because it expects the first item in the file to atoi() to 0 or 1. Amusingly enough, the probe returns AVPROBE_SCORE_MAX if there's no event ID at all, but the first event starts at a time <2 hours.
How to reproduce:
$ ffmpeg -i test.srt -f srt - ffmpeg version N-66154-g1654ca7 Copyright (c) 2000-2014 the FFmpeg developers built on Sep 5 2014 23:23:09 with Apple LLVM version 6.0 (clang-600.0.34.4) (based on LLVM 3.5svn) configuration: --extra-cflags='-march=native' --enable-optimizations --disable-stripping --enable-debug --enable-libx265 --enable-gpl --enable-libopus --enable-version3 --enable-nonfree --enable-postproc --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-gnutls --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid --prefix=/usr/local --enable-static --enable-shared --enable-avresample --enable-vda --enable-opencl --enable-libzvbi --cc=clang libavutil 54. 7.100 / 54. 7.100 libavcodec 56. 1.100 / 56. 1.100 libavformat 56. 4.100 / 56. 4.100 libavdevice 56. 0.100 / 56. 0.100 libavfilter 5. 1.100 / 5. 1.100 libavresample 2. 1. 0 / 2. 1. 0 libswscale 3. 0.100 / 3. 0.100 libswresample 1. 1.100 / 1. 1.100 libpostproc 53. 0.100 / 53. 0.100 test.srt: Invalid data found when processing input
Example file content:
3 00:00:00,000 --> 00:00:05,000 TEST1 4 00:00:05,100 --> 00:00:05,250 TEST2 5 00:00:05,500 --> 00:08:47,307 TEST3
Change History (2)
comment:1 by , 10 years ago
Keywords: | srt probe added |
---|
comment:2 by , 10 years ago
Keywords: | sub added |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Fixed in 9ae83ece8a8e92d7e9b7a077eb10d324991f0453