From 1c1c99ff23d16b07ea394c999eb530c0c072aa9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Hentschel?= Date: Sun, 15 Jan 2017 15:17:43 +0100 Subject: [PATCH] winebrowser: Fix allocation count (Coverity). MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: André Hentschel Signed-off-by: Alexandre Julliard --- programs/winebrowser/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/programs/winebrowser/main.c b/programs/winebrowser/main.c index 4ec1d143b57..304ac14bbc9 100644 --- a/programs/winebrowser/main.c +++ b/programs/winebrowser/main.c @@ -82,7 +82,7 @@ static int launch_app( const WCHAR *candidates, const WCHAR *argv1 ) { WCHAR **args = CommandLineToArgvW( candidates, &count ); - if (!(argv_new = HeapAlloc( GetProcessHeap(), 0, (count + 1) * sizeof(*argv_new) ))) break; + if (!(argv_new = HeapAlloc( GetProcessHeap(), 0, (count + 2) * sizeof(*argv_new) ))) break; for (i = 0; i < count; i++) argv_new[i] = strdup_unixcp( args[i] ); argv_new[count] = cmdline; argv_new[count + 1] = NULL;