[vlc-commits] variables: use common exit code in var_Change()
    Rémi Denis-Courmont 
    git at videolan.org
       
    Sun Jun 10 12:10:51 CEST 2018
    
    
  
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Jun  9 12:53:32 2018 +0300| [85cf41f736189159f3c83dff7b122fd07f8f988a] | committer: Rémi Denis-Courmont
variables: use common exit code in var_Change()
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=85cf41f736189159f3c83dff7b122fd07f8f988a
---
 src/misc/variables.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/misc/variables.c b/src/misc/variables.c
index 26472a465a..2de43df165 100644
--- a/src/misc/variables.c
+++ b/src/misc/variables.c
@@ -500,10 +500,9 @@ int (var_Change)(vlc_object_t *p_this, const char *psz_name,
                     break;
 
             if( i == p_var->choices.i_count )
-            {
-                /* Not found */
-                vlc_mutex_unlock( &p_priv->var_lock );
-                return VLC_EGENERIC;
+            {   /* Not found */
+                ret = VLC_EGENERIC;
+                break;
             }
 
             p_var->ops->pf_free( &p_var->choices.p_values[i] );
    
    
More information about the vlc-commits
mailing list