[vlc-devel] commit: Don't use FREENULL when that's not needed and don' t free NULL just for fun. ( Rémi Duraffort )

git version control git at videolan.org
Wed Sep 17 20:01:55 CEST 2008


vlc | branch: master | Rémi Duraffort <ivoire at videolan.org> | Wed Sep 17 19:58:11 2008 +0200| [fbd8d6fc5deaefb2f9eebb2146203c8f0985d9fd] | committer: Rémi Duraffort 

Don't use FREENULL when that's not needed and don't free NULL just for fun.

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

 modules/demux/mp4/libmp4.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/modules/demux/mp4/libmp4.c b/modules/demux/mp4/libmp4.c
index cbd9858..422f8f2 100644
--- a/modules/demux/mp4/libmp4.c
+++ b/modules/demux/mp4/libmp4.c
@@ -2885,7 +2885,7 @@ static void __MP4_BoxGet( MP4_Box_t **pp_result,
                           MP4_Box_t *p_box, const char *psz_fmt, va_list args)
 {
     char *psz_dup;
-    char    *psz_path;
+    char *psz_path;
 
     if( !p_box )
     {
@@ -2898,7 +2898,7 @@ static void __MP4_BoxGet( MP4_Box_t **pp_result,
 
     if( !psz_path || !psz_path[0] )
     {
-        FREENULL( psz_path );
+        free( psz_path );
         *pp_result = NULL;
         return;
     }
@@ -2915,7 +2915,6 @@ static void __MP4_BoxGet( MP4_Box_t **pp_result,
 //                 psz_path,psz_token,i_number );
         if( !psz_token )
         {
-            FREENULL( psz_token );
             free( psz_dup );
             *pp_result = p_box;
             return;




More information about the vlc-devel mailing list