[vlc-devel] [PATCH 34/42] ripple: reject 0 bpp formats
Rémi Denis-Courmont
remi at remlab.net
Fri Jun 28 20:30:22 CEST 2013
---
modules/video_filter/ripple.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/modules/video_filter/ripple.c b/modules/video_filter/ripple.c
index f06afe2..632a905 100644
--- a/modules/video_filter/ripple.c
+++ b/modules/video_filter/ripple.c
@@ -80,6 +80,11 @@ static int Create( vlc_object_t *p_this )
{
filter_t *p_filter = (filter_t *)p_this;
+ const vlc_chroma_description_t *p_chroma =
+ vlc_fourcc_GetChromaDescription( p_filter->fmt_in.video.i_chroma );
+ if( p_chroma == NULL || p_chroma->pixel_size == 0 )
+ return VLC_EGENERIC;
+
/* Allocate structure */
p_filter->p_sys = malloc( sizeof( filter_sys_t ) );
if( p_filter->p_sys == NULL )
--
1.8.3.1
More information about the vlc-devel
mailing list