winetest: Flush the report file to disk between each test.

Should Windows crash, this makes it easier to know which test is
responsible.

Signed-off-by: Francois Gouget <fgouget@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Francois Gouget 2017-02-08 14:12:07 +01:00 committed by Alexandre Julliard
parent d9610706e5
commit 7bc46c15ef
1 changed files with 4 additions and 0 deletions

View File

@ -626,6 +626,10 @@ run_ex (char *cmd, HANDLE out_file, const char *tempdir, DWORD ms)
PROCESS_INFORMATION pi;
DWORD wait, status;
/* Flush to disk so we know which test caused Windows to crash if it does */
if (out_file)
FlushFileBuffers(out_file);
GetStartupInfoA (&si);
si.dwFlags = STARTF_USESTDHANDLES;
si.hStdInput = GetStdHandle( STD_INPUT_HANDLE );