From: Stefan Huber Date: Tue, 18 Dec 2012 12:52:30 +0000 (+0100) Subject: echo-cancel: Fix echo-cancel-test's argument number checking X-Git-Tag: v3.99.1~205 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a99e31fb6ba8c1c04f307e11ecf66efbd4cda4b9;p=platform%2Fupstream%2Fpulseaudio.git echo-cancel: Fix echo-cancel-test's argument number checking Argument argv[5] is accessed when argc>4, which leads to an invalid access for argc==5. Fix this. Signed-off-by: Stefan Huber Acked-by: Peter Meerwald --- diff --git a/src/modules/echo-cancel/module-echo-cancel.c b/src/modules/echo-cancel/module-echo-cancel.c index 26ac30b..f7c7276 100644 --- a/src/modules/echo-cancel/module-echo-cancel.c +++ b/src/modules/echo-cancel/module-echo-cancel.c @@ -2108,7 +2108,7 @@ int main(int argc, char* argv[]) { goto fail; if (!u.ec->init(u.core, u.ec, &source_ss, &source_map, &sink_ss, &sink_map, &u.blocksize, - (argc > 4) ? argv[5] : NULL )) { + (argc > 5) ? argv[5] : NULL )) { pa_log("Failed to init AEC engine"); goto fail; }