Commit 37fdb03a authored by Filip Roséen's avatar Filip Roséen Committed by Jean-Baptiste Kempf

mkv/demux: Ebml_Parser: fix #18001 (memory-leak)

The previous implementation would not free the previous element stored
in the parser stack if an unexpected element is encountered, leading
to a memory-leak.

fixes #18001
Signed-off-by: Jean-Baptiste Kempf's avatarJean-Baptiste Kempf <>
parent 91775342
......@@ -253,6 +253,8 @@ EbmlElement *EbmlParser::Get( int n_call )
delete m_el[mi_level];
delete p_prev;
m_el[mi_level] = NULL;
m_el[mi_level - 1]->SkipData( *m_es, EBML_CONTEXT(m_el[mi_level - 1]) );
return Get();
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment