[vlc-commits] [Git][videolan/vlc][master] demux/mkv: fix header leak on error

Steve Lhomme (@robUx4) gitlab at videolan.org
Fri Aug 15 08:56:09 UTC 2025



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
e6ea9b60 by Steve Lhomme at 2025-08-15T08:40:08+00:00
demux/mkv: fix header leak on error

Fixes https://code.videolan.org/videolan/vlc/-/issues/29044

- - - - -


1 changed file:

- modules/demux/mkv/demux.cpp


Changes:

=====================================
modules/demux/mkv/demux.cpp
=====================================
@@ -75,6 +75,7 @@ bool demux_sys_t::AnalyseAllSegmentsFound( demux_t *p_demux, matroska_stream_c *
     if (std::string(doc_type) != "matroska" && std::string(doc_type) != "webm" )
     {
         msg_Err( p_demux, "Not a Matroska file : DocType = %s ", std::string(doc_type).c_str());
+        delete p_l0;
         return false;
     }
 
@@ -82,6 +83,7 @@ bool demux_sys_t::AnalyseAllSegmentsFound( demux_t *p_demux, matroska_stream_c *
     if (uint64_t(doc_read_version) > 5)
     {
         msg_Err( p_demux, "matroska file needs version %" PRId64 " but only versions 1 to 4 supported", uint64_t(doc_read_version));
+        delete p_l0;
         return false;
     }
 



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/e6ea9b6049faa430dab97d3c657cc9cfa2f3fa1f

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/e6ea9b6049faa430dab97d3c657cc9cfa2f3fa1f
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list