[vlc-commits] variables: remove first useless VLC_VAR_CLEARCHOICES parameter

Rémi Denis-Courmont git at videolan.org
Sun Jun 10 12:11:05 CEST 2018


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Jun  9 13:31:58 2018 +0300| [2a4003910b26af580afb0a45b42b677308591919] | committer: Rémi Denis-Courmont

variables: remove first useless VLC_VAR_CLEARCHOICES parameter

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

 src/audio_output/output.c      | 2 +-
 src/input/control.c            | 2 +-
 src/input/event.c              | 2 +-
 src/input/var.c                | 4 ++--
 src/video_output/interlacing.c | 4 ++--
 test/src/misc/variables.c      | 2 +-
 6 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/audio_output/output.c b/src/audio_output/output.c
index 91d21d394c..b17a049d8e 100644
--- a/src/audio_output/output.c
+++ b/src/audio_output/output.c
@@ -425,7 +425,7 @@ static void aout_PrepareStereoMode (audio_output_t *aout,
     aout_owner_t *owner = aout_owner (aout);
 
     /* Fill Stereo mode choices */
-    var_Change (aout, "stereo-mode", VLC_VAR_CLEARCHOICES, NULL);
+    var_Change(aout, "stereo-mode", VLC_VAR_CLEARCHOICES);
     vlc_value_t val, txt;
     val.i_int = 0;
 
diff --git a/src/input/control.c b/src/input/control.c
index c5eca32e96..aacee5e813 100644
--- a/src/input/control.c
+++ b/src/input/control.c
@@ -597,7 +597,7 @@ static void UpdateBookmarksOption( input_thread_t *p_input )
     vlc_memstream_puts( &vstr, "bookmarks=" );
 
     vlc_mutex_lock( &priv->p_item->lock );
-    var_Change( p_input, "bookmark", VLC_VAR_CLEARCHOICES, 0 );
+    var_Change( p_input, "bookmark", VLC_VAR_CLEARCHOICES );
 
     for( int i = 0; i < priv->i_bookmark; i++ )
     {
diff --git a/src/input/event.c b/src/input/event.c
index a1307a9587..2881c42712 100644
--- a/src/input/event.c
+++ b/src/input/event.c
@@ -329,7 +329,7 @@ static void VarListDel( input_thread_t *p_input,
     }
     else
     {
-        var_Change( p_input, psz_variable, VLC_VAR_CLEARCHOICES, &val );
+        var_Change( p_input, psz_variable, VLC_VAR_CLEARCHOICES );
     }
 
     Trigger( p_input, i_event );
diff --git a/src/input/var.c b/src/input/var.c
index 0562acc8be..bedad376e8 100644
--- a/src/input/var.c
+++ b/src/input/var.c
@@ -289,7 +289,7 @@ void input_ControlVarNavigation( input_thread_t *p_input )
     }
 
     /* Create titles and chapters */
-    var_Change( p_input, "title", VLC_VAR_CLEARCHOICES, NULL );
+    var_Change( p_input, "title", VLC_VAR_CLEARCHOICES );
 
     for( int i = 0; i < input_priv(p_input)->i_title; i++ )
     {
@@ -388,7 +388,7 @@ void input_ControlVarTitle( input_thread_t *p_input, int i_title )
     }
 
     /* Build chapter list */
-    var_Change( p_input, "chapter", VLC_VAR_CLEARCHOICES, NULL );
+    var_Change( p_input, "chapter", VLC_VAR_CLEARCHOICES );
     for( i = 0; i <  t->i_seekpoint; i++ )
     {
         vlc_value_t val;
diff --git a/src/video_output/interlacing.c b/src/video_output/interlacing.c
index e3a889e733..ee9f6b42bf 100644
--- a/src/video_output/interlacing.c
+++ b/src/video_output/interlacing.c
@@ -113,7 +113,7 @@ void vout_InitInterlacingSupport(vout_thread_t *vout, bool is_interlaced)
     var_Change(vout, "deinterlace", VLC_VAR_SETTEXT, &text);
 
     const module_config_t *optd = config_FindConfig("deinterlace");
-    var_Change(vout, "deinterlace", VLC_VAR_CLEARCHOICES, NULL);
+    var_Change(vout, "deinterlace", VLC_VAR_CLEARCHOICES);
     if (likely(optd != NULL))
         for (unsigned i = 0; i < optd->list_count; i++) {
             val.i_int = optd->list.i[i];
@@ -129,7 +129,7 @@ void vout_InitInterlacingSupport(vout_thread_t *vout, bool is_interlaced)
     var_Change(vout, "deinterlace-mode", VLC_VAR_SETTEXT, &text);
 
     const module_config_t *optm = config_FindConfig("deinterlace-mode");
-    var_Change(vout, "deinterlace-mode", VLC_VAR_CLEARCHOICES, NULL);
+    var_Change(vout, "deinterlace-mode", VLC_VAR_CLEARCHOICES);
     if (likely(optm != NULL))
         for (unsigned i = 0; i < optm->list_count; i++) {
              if (!DeinterlaceIsModeValid(optm->list.psz[i]))
diff --git a/test/src/misc/variables.c b/test/src/misc/variables.c
index aa2be7e47e..9394fde24d 100644
--- a/test/src/misc/variables.c
+++ b/test/src/misc/variables.c
@@ -344,7 +344,7 @@ static void test_choices( libvlc_int_t *p_libvlc )
             !strcmp( val2.p_list->p_values[0].psz_string, "one" ) );
     var_FreeList( &val, &val2 );
 
-    var_Change( p_libvlc, "bla", VLC_VAR_CLEARCHOICES, NULL );
+    var_Change( p_libvlc, "bla", VLC_VAR_CLEARCHOICES );
     assert( var_CountChoices( p_libvlc, "bla" ) == 0 );
 
     var_Destroy( p_libvlc, "bla" );



More information about the vlc-commits mailing list