[vlc-devel] [PATCH] Don't delete es at EOF in Demux() but in Close()
Denis Charmet
typx at dinauz.org
Tue Jan 24 01:24:49 CET 2012
Fix the second part of #5896
---
modules/demux/mkv/mkv.cpp | 9 +++++++--
1 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/modules/demux/mkv/mkv.cpp b/modules/demux/mkv/mkv.cpp
index 2c1087e..d9eea9a 100644
--- a/modules/demux/mkv/mkv.cpp
+++ b/modules/demux/mkv/mkv.cpp
@@ -257,6 +257,13 @@ static void Close( vlc_object_t *p_this )
{
demux_t *p_demux = (demux_t*)p_this;
demux_sys_t *p_sys = p_demux->p_sys;
+ virtual_segment_c *p_vsegment = p_sys->p_current_segment;
+ if( p_vsegment )
+ {
+ matroska_segment_c *p_segment = p_vsegment->CurrentSegment();
+ if( p_segment )
+ p_segment->UnSelect();
+ }
delete p_sys;
}
@@ -691,8 +698,6 @@ static int Demux( demux_t *p_demux)
else
{
msg_Warn( p_demux, "cannot get block EOF?" );
- p_segment->UnSelect();
-
es_out_Control( p_demux->out, ES_OUT_RESET_PCR );
break;
}
--
1.7.8.3
More information about the vlc-devel
mailing list