Obviously the most controversial patch in this set. I'd like to know what program exactly that produced the broken file in ticket #5032 so that we can send the guilty party to parsing jail More seriously, eating any run of CR CR CR... is incredibly broken and is part of the reason for the convoluted parsing logic in srtdec before this patchset. A compromise solution could be to peek two bytes forward and see if the line ending is CR CR LF. My guess is the file was produced by running unix2dos on a file with CR LF, thus converting the LF to CR LF. webvttdec is better with this, probably because these kinds of line ending is explicitly banned by the WebVTT spec. That is, CR CR LF is to be treated as two line endings, no ifs or buts about it. /Tomas