Allow --sub-track to work with EIA-608 captions, and fix crash on exit
Prior to this patch, if the user specified the --sub-track argument on the command line, it would not work with MPEG2 streams that contain EIA-608 closed captions. It would also cause an abort() on exit. The crash was because the various functions that select/unselect streams would check for the p_master member, which isn't set until after EsOutAdd(). The call to EsOutAdd itself though would call EsSelect(), which would treat the ES as a regular subtitle stream and cause a resource leak -- which would cause an abort at exit. The other change actually makes --sub-track work with the special case of EIA-608 captions. Signed-off-by:Rafaël Carré <funman@videolan.org>
Showing
Please register or sign in to comment