[vlc-commits] wall: reject 0 planes formats

Rémi Denis-Courmont git at videolan.org
Sun Jul 7 20:13:41 CEST 2013


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Jun 23 09:14:46 2013 +0300| [3986d69c91d715f05a3d48d1873a4473f3ec87e6] | committer: Rémi Denis-Courmont

wall: reject 0 planes formats

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

 modules/video_filter/wall.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/modules/video_filter/wall.c b/modules/video_filter/wall.c
index 8c965ab..24e9384 100644
--- a/modules/video_filter/wall.c
+++ b/modules/video_filter/wall.c
@@ -123,6 +123,11 @@ static int Open( vlc_object_t *p_this )
     video_splitter_t *p_splitter = (video_splitter_t*)p_this;
     video_splitter_sys_t *p_sys;
 
+    const vlc_chroma_description_t *p_chroma =
+        vlc_fourcc_GetChromaDescription( p_splitter->fmt.i_chroma );
+    if( p_chroma == NULL || p_chroma->plane_count == 0 )
+        return VLC_EGENERIC;
+
     p_splitter->p_sys = p_sys = malloc( sizeof(*p_sys) );
     if( !p_sys )
         return VLC_ENOMEM;



More information about the vlc-commits mailing list