Huw Davies (@huw) commented about dlls/user32/tests/clipboard.c:
- r = open_clipboard( hwnd );
- ok( r, "Open clipboard failed: %#lx.\n", GetLastError() );
- r = EmptyClipboard();
- ok( r, "EmptyClipboard failed: %#lx.\n", GetLastError() );
- bitmap = CreateBitmap( 10, 10, 1, 1, NULL );
- h = SetClipboardData( CF_BITMAP, bitmap );
- ok( h == bitmap, "Expected bitmap %p, got %p.\n", bitmap, h );
- ok( !!DeleteObject( bitmap ), "DeleteObject failed.\n" );
- h = GetClipboardData( CF_BITMAP );
- ok( h == bitmap, "Expected bitmap %p, got %p.\n", bitmap, h );
- memset( &bmi, 0, sizeof(bmi) );
- bmi.bmiHeader.biSize = sizeof(BITMAPINFOHEADER);
- result = GetDIBits( GetDC( 0 ), h, 0, 0, NULL, &bmi, 0 );
- todo_wine ok( !!result && result != ERROR_INVALID_PARAMETER, "GetDIBits failed: %#lx.\n", GetLastError() );
I doubt `GetDIBits()` returns `ERROR_INVALID_PARAMETER`, that's likely a mistake in msdn and probably refers to the result of calling `GetLastError()`. Just testing for a non-zero return should be fine.