Update demuxer->sub->id and demuxer->sub->sh if a new subtitle stream is

created that matches the user-requested one.
Fixes -slang and -sid with DVDs (anything that uses demux_mpg actually).


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29095 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2009-03-29 11:21:18 +00:00
parent bdbf4f617d
commit 20a4844e80
1 changed files with 4 additions and 0 deletions

View File

@ -259,6 +259,10 @@ sh_sub_t *new_sh_sub_sid(demuxer_t *demuxer, int id, int sid)
sh->sid = sid;
mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_SUBTITLE_ID=%d\n", sid);
}
if (sid == dvdsub_id) {
demuxer->sub->id = id;
demuxer->sub->sh = demuxer->s_streams[id];
}
return demuxer->s_streams[id];
}