[vlc-commits] m3u: Fix inverted logic

Hugo Beauzée-Luyssen git at videolan.org
Wed Apr 19 11:22:23 CEST 2017


vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Wed Apr 19 11:16:50 2017 +0200| [90a013c50647d4018ddf9379ac5f0898da049a60] | committer: Hugo Beauzée-Luyssen

m3u: Fix inverted logic

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

 modules/demux/playlist/m3u.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/demux/playlist/m3u.c b/modules/demux/playlist/m3u.c
index 98798e306d..8137ac3284 100644
--- a/modules/demux/playlist/m3u.c
+++ b/modules/demux/playlist/m3u.c
@@ -81,7 +81,7 @@ int Import_M3U( vlc_object_t *p_this )
 
     if( demux_IsPathExtension( p_demux, ".m3u8" )
      || demux_IsForced( p_demux, "m3u8" )
-     || (type != NULL && strcasecmp(type, "application/vnd.apple.mpegurl")))
+     || (type != NULL && !strcasecmp(type, "application/vnd.apple.mpegurl")))
     {
         pf_dup = CheckUnicode; /* UTF-8 file type */
         free(type);
@@ -91,7 +91,7 @@ int Import_M3U( vlc_object_t *p_this )
      || demux_IsPathExtension( p_demux, ".vlc" )
      || demux_IsForced( p_demux, "m3u" )
      || ContainsURL( p_demux )
-     || (type != NULL && strcasecmp(type, "audio/x-mpegurl")))
+     || (type != NULL && !strcasecmp(type, "audio/x-mpegurl")))
         free(type); /* Guess encoding */
     else
     {



More information about the vlc-commits mailing list