ffmpeg | branch: master | Michael Niedermayer <michae...@gmx.at> | Fri Jan 23 
15:03:40 2015 +0100| [579795b2049bc8b0f291b302e7ab24f9561eaf24] | committer: 
Michael Niedermayer

avfilter/af_channelmap: Check for missing argument in get_channel_idx()

Fixes null pointer dereference

Signed-off-by: Michael Niedermayer <michae...@gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=579795b2049bc8b0f291b302e7ab24f9561eaf24
---

 libavfilter/af_channelmap.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavfilter/af_channelmap.c b/libavfilter/af_channelmap.c
index c3454c5..2a43c12 100644
--- a/libavfilter/af_channelmap.c
+++ b/libavfilter/af_channelmap.c
@@ -93,6 +93,8 @@ static int get_channel_idx(char **map, int *ch, char delim, 
int max_ch)
     int n = 0;
     if (!next && delim == '-')
         return AVERROR(EINVAL);
+    if (!*map)
+        return AVERROR(EINVAL);
     len = strlen(*map);
     sscanf(*map, "%d%n", ch, &n);
     if (n != len)

_______________________________________________
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

Reply via email to