[MPlayer-dev-eng] [patch] command.c does not update set_of_ass_tracks together with set_of_subtitles

Yuriy Kaminskiy yumkam at mail.ru
Fri Jan 22 10:21:15 CET 2010


Hello!

When in command.c mplayer manipulates mpctx->set_of_subtitles, it does not
update mpctx->set_of_ass_tracks too. This leads to memory leaks and desync
between set_of_subtitles and set_of_ass_tracks contents: (with -ass) load 1.srt
2.srt, remove 1.srt, then switch to 2.srt, this will display ass-ified data from
1.srt.

Also I think that missed ass_track = NULL; can cause (with some (un)luck)
sigsegv on sub_remove current subtitle file with ass_enabled (but I'm not sure
if this scenario is real on [unpatched] mplayer; well, at least with partially
applied patch it /is/ real ;-)).

Patch applies to current svn (r30384) too.

Second part should solve similar problem for gui-loaded subs (not tested).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ass-remove-subtitle.patch
Type: text/x-diff
Size: 2289 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20100122/b79755fb/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ass_remove_subtitle-for-gui.patch
Type: text/x-diff
Size: 1807 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20100122/b79755fb/attachment-0001.patch>


More information about the MPlayer-dev-eng mailing list