winetest: Detect if an unhandled exception occurred in a child process and print an appropriate message.

Avoid getting caught incrementing the failure count in this case, as it 
could take a very long time to complete.
oldstable
Rob Shearman 2008-05-07 11:10:51 +01:00 committed by Alexandre Julliard
parent 2dc9ed3006
commit ce42c95a1c
1 changed files with 12 additions and 4 deletions

View File

@ -352,10 +352,18 @@ void winetest_wait_child_process( HANDLE process )
if (exit_code)
{
fprintf( stdout, "%s: %u failures in child process\n",
current_test->name, exit_code );
while (exit_code-- > 0)
InterlockedIncrement(&failures);
if (exit_code > 255)
{
fprintf( stdout, "%s: exception 0x%08x in child process\n", current_test->name, exit_code );
InterlockedIncrement( &failures );
}
else
{
fprintf( stdout, "%s: %u failures in child process\n",
current_test->name, exit_code );
while (exit_code-- > 0)
InterlockedIncrement(&failures);
}
}
}