[vlc-commits] Prevent potential null pointer dereference in zip access

Gabriel de Perthuis git at videolan.org
Tue Feb 10 14:14:48 CET 2015


vlc/vlc-2.1 | branch: master | Gabriel de Perthuis <g2p.code at gmail.com> | Mon Sep 15 12:35:46 2014 +0200| [430e3207d65f1e50bd77d27960edae61f3c04060] | committer: Jean-Baptiste Kempf

Prevent potential null pointer dereference in zip access

Close #12149

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
(cherry picked from commit 3c53c13138225c4b2414ab8358847197cf29b718)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.1.git/?a=commit;h=430e3207d65f1e50bd77d27960edae61f3c04060
---

 modules/access/zip/zipstream.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/access/zip/zipstream.c b/modules/access/zip/zipstream.c
index f505738..3bb9232 100644
--- a/modules/access/zip/zipstream.c
+++ b/modules/access/zip/zipstream.c
@@ -715,7 +715,7 @@ static node* findOrCreateParentNode( node *root, const char *fullpath )
 
     while( current )
     {
-        if( !strcmp( current->name, folder ) )
+        if( current->name && !strcmp( current->name, folder ) )
         {
             /* We found the folder, go recursively deeper */
             return findOrCreateParentNode( current, sep );



More information about the vlc-commits mailing list