[vlc-devel] commit: blue screen: __MIN and __MAX are not expansion-safe ( Rémi Denis-Courmont )
git version control
git at videolan.org
Tue May 19 19:59:17 CEST 2009
vlc | branch: 1.0-bugfix | Rémi Denis-Courmont <remi at remlab.net> | Tue May 19 19:53:05 2009 +0300| [ddba74088f04b364225cad6d81bd908d70cdad95] | committer: Rémi Denis-Courmont
blue screen: __MIN and __MAX are not expansion-safe
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ddba74088f04b364225cad6d81bd908d70cdad95
---
modules/video_filter/bluescreen.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/modules/video_filter/bluescreen.c b/modules/video_filter/bluescreen.c
index e2b4442..5af9b20 100644
--- a/modules/video_filter/bluescreen.c
+++ b/modules/video_filter/bluescreen.c
@@ -130,9 +130,10 @@ static int Create( vlc_object_t *p_this )
config_ChainParse( p_filter, CFG_PREFIX, ppsz_filter_options,
p_filter->p_cfg );
+ int val;
#define GET_VAR( name, min, max ) \
- p_sys->i_##name = __MIN( max, __MAX( min, \
- var_CreateGetIntegerCommand( p_filter, CFG_PREFIX #name ) ) ); \
+ val = var_CreateGetIntegerCommand( p_filter, CFG_PREFIX #name ); \
+ p_sys->i_##name = __MIN( max, __MAX( min, val ) ); \
var_AddCallback( p_filter, CFG_PREFIX #name, BluescreenCallback, p_sys );
GET_VAR( u, 0x00, 0xff );
More information about the vlc-devel
mailing list