[vlc-commits] dash: BasicCMParser: Avoid potential crash when inheriting mimeType

Hugo Beauzée-Luyssen git at videolan.org
Wed May 30 12:08:24 CEST 2012


vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Wed May 30 11:42:04 2012 +0200| [981dcf74f0bf4bc5fe684931f7d32135e0b5342b] | committer: Hugo Beauzée-Luyssen

dash: BasicCMParser: Avoid potential crash when inheriting mimeType

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=981dcf74f0bf4bc5fe684931f7d32135e0b5342b
---

 modules/stream_filter/dash/mpd/BasicCMParser.cpp |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/modules/stream_filter/dash/mpd/BasicCMParser.cpp b/modules/stream_filter/dash/mpd/BasicCMParser.cpp
index 968d107..047e4e2 100644
--- a/modules/stream_filter/dash/mpd/BasicCMParser.cpp
+++ b/modules/stream_filter/dash/mpd/BasicCMParser.cpp
@@ -567,7 +567,8 @@ bool    BasicCMParser::parseCommonAttributesElements( Node *node, CommonAttribut
             return false;
         }
     }
-    common->setMimeType( it->second );
+    else
+        common->setMimeType( it->second );
     //Everything else is optionnal.
     it = attr.find( "width" );
     if ( it != attr.end() )



More information about the vlc-commits mailing list