kernel32/tests: Convert fiber back to thread even when IsThreadAFiber is not available.

Signed-off-by: Bernhard Übelacker <bernhardu@mailbox.org>
Signed-off-by: André Hentschel <nerv@dawncrow.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Bernhard Übelacker 2016-08-06 14:40:10 +02:00 committed by Alexandre Julliard
parent d22964d952
commit e2253d439f
1 changed files with 10 additions and 18 deletions

View File

@ -155,28 +155,20 @@ static void test_FiberHandling(void)
ok(fiberCount == 1, "Wrong fiber count: %d\n", fiberCount);
pDeleteFiber(fibers[1]);
if (!pCreateFiberEx)
if (pCreateFiberEx)
{
win_skip( "CreateFiberEx not present\n" );
return;
}
fibers[1] = pCreateFiberEx(0,0,0,FiberMainProc,&testparam);
ok(fibers[1] != NULL, "CreateFiberEx failed with error %u\n", GetLastError());
pSwitchToFiber(fibers[1]);
ok(fiberCount == 2, "Wrong fiber count: %d\n", fiberCount);
pDeleteFiber(fibers[1]);
if (!pIsThreadAFiber)
{
win_skip( "IsThreadAFiber not present\n" );
return;
}
else win_skip( "CreateFiberEx not present\n" );
ok(pIsThreadAFiber(), "IsThreadAFiber reported FALSE\n");
if (pIsThreadAFiber) ok(pIsThreadAFiber(), "IsThreadAFiber reported FALSE\n");
test_ConvertFiberToThread();
ok(!pIsThreadAFiber(), "IsThreadAFiber reported TRUE\n");
if (pIsThreadAFiber) ok(!pIsThreadAFiber(), "IsThreadAFiber reported TRUE\n");
}
static void test_FiberLocalStorage(void)