[vlc-commits] addons: fsstorage: move initializer

Francois Cartegnie git at videolan.org
Wed Feb 12 02:36:57 CET 2014


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Feb 12 01:29:56 2014 +0100| [ad5dda257a219f1b2f267f2780ff02e4e9053325] | committer: Francois Cartegnie

addons: fsstorage: move initializer

cid #1170824

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

 modules/misc/addons/fsstorage.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/modules/misc/addons/fsstorage.c b/modules/misc/addons/fsstorage.c
index e0f51e2..92647d7 100644
--- a/modules/misc/addons/fsstorage.c
+++ b/modules/misc/addons/fsstorage.c
@@ -520,7 +520,7 @@ static int WriteCatalog( addons_storage_t *p_storage,
 {
     addon_entry_t *p_entry;
     char *psz_file;
-    char *psz_tempstring = NULL;
+    char *psz_tempstring;
     char *psz_userdir = config_GetUserDir( VLC_DATA_DIR );
     if ( !psz_userdir ) return VLC_ENOMEM;
 
@@ -562,6 +562,8 @@ static int WriteCatalog( addons_storage_t *p_storage,
     {
         p_entry = pp_entries[i];
         vlc_mutex_lock( &p_entry->lock );
+        psz_tempstring = NULL;
+
         if ( ( p_entry->e_state != ADDON_INSTALLED ) ||
              !( p_entry->e_flags & ADDON_MANAGEABLE ) )
         {



More information about the vlc-commits mailing list