mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-02-14 21:23:42 +00:00
WEBVTT header lacks empty newline #196
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @atrottmann on GitHub (Nov 4, 2016).
Using the WEBVTT files generated by ccextractor in a HTML5 video context, I have noticed that the first entry is skipped by the browser. Apparently this is the case because it expects an empty line between the WEBVTT header and the first subtitle entry.
Changing line 60 of src/lib_ccx/ccx_encoders_common.c to include a second pair of \r\n appears to fix the problem:
static const char *webvtt_header = "WEBVTT\r\n\r\n";
Kind regards,
Andreas Trottmann
@cfsmp3 commented on GitHub (Nov 4, 2016):
Adding that \r\n is the correct fix but not there - otherwise we cannot add more data to the header before the body starts. We're not doing it for now, but definitely we don't want to make it impossible by adding the header terminator in the same place the file signature is.
Anyway, fixed now in master.