Should fix https://bugs.winehq.org/show_bug.cgi?id=51827
I tested this on a Windows 10 VM. With last=4 it failed about 50% of the time, with last=3 it passed 100 tests without any failures.
-- v4: d3dx10/tests: Disable a PreloadGlyphs test for d3dx10_34.
From: Sven Baars sbaars@codeweavers.com
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51827 Signed-off-by: Sven Baars sbaars@codeweavers.com --- dlls/d3dx10_34/tests/Makefile.in | 2 +- dlls/d3dx10_35/tests/Makefile.in | 2 +- dlls/d3dx10_36/tests/Makefile.in | 2 +- dlls/d3dx10_37/tests/Makefile.in | 2 +- dlls/d3dx10_38/tests/Makefile.in | 2 +- dlls/d3dx10_39/tests/Makefile.in | 2 +- dlls/d3dx10_40/tests/Makefile.in | 2 +- dlls/d3dx10_41/tests/Makefile.in | 2 +- dlls/d3dx10_42/tests/Makefile.in | 2 +- dlls/d3dx10_43/tests/Makefile.in | 2 +- dlls/d3dx10_43/tests/d3dx10.c | 8 ++++++-- 11 files changed, 16 insertions(+), 12 deletions(-)
diff --git a/dlls/d3dx10_34/tests/Makefile.in b/dlls/d3dx10_34/tests/Makefile.in index 77795f87885..b3cb20f944e 100644 --- a/dlls/d3dx10_34/tests/Makefile.in +++ b/dlls/d3dx10_34/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=34 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_34.dll IMPORTS = d3dx10_34 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_35/tests/Makefile.in b/dlls/d3dx10_35/tests/Makefile.in index 95777543e56..5d15ac0f99a 100644 --- a/dlls/d3dx10_35/tests/Makefile.in +++ b/dlls/d3dx10_35/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=35 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_35.dll IMPORTS = d3dx10_35 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_36/tests/Makefile.in b/dlls/d3dx10_36/tests/Makefile.in index d2cd9c02350..a9503459208 100644 --- a/dlls/d3dx10_36/tests/Makefile.in +++ b/dlls/d3dx10_36/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=36 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_36.dll IMPORTS = d3dx10_36 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_37/tests/Makefile.in b/dlls/d3dx10_37/tests/Makefile.in index 505f85d0c4b..e5707117a73 100644 --- a/dlls/d3dx10_37/tests/Makefile.in +++ b/dlls/d3dx10_37/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=37 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_37.dll IMPORTS = d3dx10_37 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_38/tests/Makefile.in b/dlls/d3dx10_38/tests/Makefile.in index b5da90a2f97..c1507422b4d 100644 --- a/dlls/d3dx10_38/tests/Makefile.in +++ b/dlls/d3dx10_38/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=38 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_38.dll IMPORTS = d3dx10_38 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_39/tests/Makefile.in b/dlls/d3dx10_39/tests/Makefile.in index 63190f1e090..fadaf089165 100644 --- a/dlls/d3dx10_39/tests/Makefile.in +++ b/dlls/d3dx10_39/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=39 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_39.dll IMPORTS = d3dx10_39 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_40/tests/Makefile.in b/dlls/d3dx10_40/tests/Makefile.in index 669ef97d4f7..f5ffaf385a8 100644 --- a/dlls/d3dx10_40/tests/Makefile.in +++ b/dlls/d3dx10_40/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=40 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_40.dll IMPORTS = d3dx10_40 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_41/tests/Makefile.in b/dlls/d3dx10_41/tests/Makefile.in index 85204bc4f2a..afff1c75705 100644 --- a/dlls/d3dx10_41/tests/Makefile.in +++ b/dlls/d3dx10_41/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=41 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_41.dll IMPORTS = d3dx10_41 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_42/tests/Makefile.in b/dlls/d3dx10_42/tests/Makefile.in index 8936c5859e7..f996b86b0e6 100644 --- a/dlls/d3dx10_42/tests/Makefile.in +++ b/dlls/d3dx10_42/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=42 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_42.dll IMPORTS = d3dx10_42 ole32 gdi32 PARENTSRC = ../../d3dx10_43/tests diff --git a/dlls/d3dx10_43/tests/Makefile.in b/dlls/d3dx10_43/tests/Makefile.in index 5cef10c80ff..95078d0e12b 100644 --- a/dlls/d3dx10_43/tests/Makefile.in +++ b/dlls/d3dx10_43/tests/Makefile.in @@ -1,4 +1,4 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES +EXTRADEFS = -DD3DX10_SDK_VERSION=43 -DWINE_NO_LONG_TYPES TESTDLL = d3dx10_43.dll IMPORTS = d3dx10 ole32 gdi32
diff --git a/dlls/d3dx10_43/tests/d3dx10.c b/dlls/d3dx10_43/tests/d3dx10.c index 9b7a4d7cc9b..4a734fe0149 100644 --- a/dlls/d3dx10_43/tests/d3dx10.c +++ b/dlls/d3dx10_43/tests/d3dx10.c @@ -2466,11 +2466,15 @@ static void test_font(void) hr = ID3DX10Font_PreloadCharacters(font, 'a', 'z'); ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
- /* Test glyphs that are not rendered */ - hr = ID3DX10Font_PreloadGlyphs(font, 0, 5); +#if D3DX10_SDK_VERSION > 34 + /* Test multiple textures. + * Native d3dx10_34.dll shows signs of memory corruption in this call. */ + hr = ID3DX10Font_PreloadGlyphs(font, 0, 1000); todo_wine ok(hr == S_OK, "Unexpected hr %#x.\n", hr); +#endif
+ /* Test glyphs that are not rendered */ for (glyph = 1; glyph < 4; ++glyph) { srv = (void *)0xdeadbeef;