[vlc-commits] mkv: Don't attempt to print null strings
Hugo Beauzée-Luyssen
git at videolan.org
Wed May 3 12:39:37 CEST 2017
vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Wed May 3 11:13:52 2017 +0200| [7a726a53d3781982ce6197be5eb011aae00a4769] | committer: Hugo Beauzée-Luyssen
mkv: Don't attempt to print null strings
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7a726a53d3781982ce6197be5eb011aae00a4769
---
modules/demux/mkv/matroska_segment_parse.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/modules/demux/mkv/matroska_segment_parse.cpp b/modules/demux/mkv/matroska_segment_parse.cpp
index d1b02f2c9a..d2dd03008e 100644
--- a/modules/demux/mkv/matroska_segment_parse.cpp
+++ b/modules/demux/mkv/matroska_segment_parse.cpp
@@ -375,14 +375,14 @@ void matroska_segment_c::ParseTrackEntry( const KaxTrackEntry *m )
E_CASE( KaxTrackName, tname )
{
vars.tk->fmt.psz_description = ToUTF8( UTFstring( tname ) );
- debug( vars, "Track Name=%s", vars.tk->fmt.psz_description ) ;
+ debug( vars, "Track Name=%s", vars.tk->fmt.psz_description ? vars.tk->fmt.psz_description : "(null)" );
}
E_CASE( KaxTrackLanguage, lang )
{
free( vars.tk->fmt.psz_language );
const std::string slang ( lang );
vars.tk->fmt.psz_language = strndup( slang.c_str (), slang.find_first_of( '-' ) );
- debug( vars, "Track Language=`%s'", vars.tk->fmt.psz_language );
+ debug( vars, "Track Language=`%s'", vars.tk->fmt.psz_language ? vars.tk->fmt.psz_language : "(null)" );
}
E_CASE( KaxCodecID, codecid )
{
More information about the vlc-commits
mailing list