[vlc-devel] commit: mosaic: fix a dummy warning (and add a missing undef). ( Rémi Duraffort )

git version control git at videolan.org
Sun Mar 22 18:18:02 CET 2009


vlc | branch: master | Rémi Duraffort <ivoire at videolan.org> | Sun Mar 22 18:11:39 2009 +0100| [3107779f000835a131b18645d28788e4fa3b7e3c] | committer: Rémi Duraffort 

mosaic: fix a dummy warning (and add a missing undef).

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

 modules/video_filter/mosaic.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/modules/video_filter/mosaic.c b/modules/video_filter/mosaic.c
index d2cc52c..fdc506c 100644
--- a/modules/video_filter/mosaic.c
+++ b/modules/video_filter/mosaic.c
@@ -288,6 +288,7 @@ static int CreateFilter( vlc_object_t *p_this )
     char *psz_offsets;
     int i_index;
     vlc_value_t val;
+    int i_command;
 
     /* The mosaic thread is more important than the decoder threads */
     vlc_thread_set_priority( p_this, VLC_THREAD_PRIORITY_OUTPUT );
@@ -310,8 +311,8 @@ static int CreateFilter( vlc_object_t *p_this )
                        p_filter->p_cfg );
 
 #define GET_VAR( name, min, max )                                           \
-    p_sys->i_##name = __MIN( max, __MAX( min,                               \
-        var_CreateGetIntegerCommand( p_filter, CFG_PREFIX #name ) ) );      \
+    i_command = var_CreateGetIntegerCommand( p_filter, CFG_PREFIX #name );  \
+    p_sys->i_##name = __MIN( max, __MAX( min, i_command ) );                \
     var_AddCallback( p_filter, CFG_PREFIX #name, MosaicCallback, p_sys );
 
     GET_VAR( width, 0, INT_MAX );
@@ -330,6 +331,7 @@ static int CreateFilter( vlc_object_t *p_this )
     GET_VAR( alpha, 0, 255 );
     GET_VAR( position, 0, 2 );
     GET_VAR( delay, 100, INT_MAX );
+#undef GET_VAR
     p_sys->i_delay *= 1000;
 
     p_sys->b_ar = var_CreateGetBoolCommand( p_filter,




More information about the vlc-devel mailing list