winebrowser: Fix allocation count (Coverity).

Signed-off-by: André Hentschel <nerv@dawncrow.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
oldstable
André Hentschel 2017-01-15 15:17:43 +01:00 committed by Alexandre Julliard
parent fa54b5d376
commit 1c1c99ff23
1 changed files with 1 additions and 1 deletions

View File

@ -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;