opengl32/tests: Don't test function directly when reporting GetLastError().

Signed-off-by: André Hentschel <nerv@dawncrow.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
André Hentschel 2020-12-19 16:00:39 +01:00 committed by Alexandre Julliard
parent 301d7204f9
commit 77047c76dd
1 changed files with 3 additions and 2 deletions

View File

@ -235,9 +235,10 @@ static int test_pfd(const PIXELFORMATDESCRIPTOR *pfd, PIXELFORMATDESCRIPTOR *fmt
pf = ChoosePixelFormat( hdc, pfd );
if (pf && fmt)
{
INT ret;
memset(fmt, 0, sizeof(*fmt));
ok(DescribePixelFormat( hdc, pf, sizeof(*fmt), fmt ),
"DescribePixelFormat failed with error: %u\n", GetLastError());
ret = DescribePixelFormat( hdc, pf, sizeof(*fmt), fmt );
ok(ret, "DescribePixelFormat failed with error: %u\n", GetLastError());
}
ReleaseDC( hwnd, hdc );
DestroyWindow( hwnd );