From 5ec57827afcfa96f72ca42b0fbd7150c3c6254c6 Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Fri, 21 Jul 2017 04:24:04 +0200 Subject: [PATCH] d3dx9_36-D3DXOptimizeVertices: Add a missing test-only patch. --- ...emove-useless-n-within-some-ok-messa.patch | 64 +++++++++++++++++++ ...-semi-stub-for-D3DXOptimizeVertices.patch} | 0 patches/patchinstall.sh | 4 +- 3 files changed, 67 insertions(+), 1 deletion(-) create mode 100644 patches/d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-tests-Remove-useless-n-within-some-ok-messa.patch rename patches/d3dx9_36-D3DXOptimizeVertices/{0001-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch => 0002-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch} (100%) diff --git a/patches/d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-tests-Remove-useless-n-within-some-ok-messa.patch b/patches/d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-tests-Remove-useless-n-within-some-ok-messa.patch new file mode 100644 index 00000000..5642fbb9 --- /dev/null +++ b/patches/d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-tests-Remove-useless-n-within-some-ok-messa.patch @@ -0,0 +1,64 @@ +From 0c19922d2d7f8f14cfa8642f06b3f76e5a07029e Mon Sep 17 00:00:00 2001 +From: Christian Costa +Date: Sun, 16 Jul 2017 17:39:28 +0200 +Subject: d3dx9_36/tests: Remove useless \n within some ok messages. + +--- + dlls/d3dx9_36/tests/mesh.c | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +diff --git a/dlls/d3dx9_36/tests/mesh.c b/dlls/d3dx9_36/tests/mesh.c +index f803938537f..07c978265c8 100644 +--- a/dlls/d3dx9_36/tests/mesh.c ++++ b/dlls/d3dx9_36/tests/mesh.c +@@ -10403,10 +10403,10 @@ static void test_clone_mesh(void) + + hr = mesh->lpVtbl->CloneMesh(mesh, tc[i].clone_options, tc[i].new_declaration, + test_context->device, &mesh_clone); +- ok(hr == D3D_OK, "CloneMesh test case %d failed. Got %x\n, expected D3D_OK\n", i, hr); ++ ok(hr == D3D_OK, "CloneMesh test case %d failed. Got %x, expected D3D_OK\n", i, hr); + + hr = mesh_clone->lpVtbl->GetDeclaration(mesh_clone, new_declaration); +- ok(hr == D3D_OK, "GetDeclaration test case %d failed. Got %x\n, expected D3D_OK\n", i, hr); ++ ok(hr == D3D_OK, "GetDeclaration test case %d failed. Got %x, expected D3D_OK\n", i, hr); + /* Check declaration elements */ + for (j = 0; tc[i].new_declaration[j].Stream != 0xFF; j++) + { +@@ -10593,7 +10593,7 @@ static void test_valid_mesh(void) + + hr = D3DXValidMesh(mesh, tc[i].adjacency, &errors_and_warnings); + todo_wine ok(hr == tc[i].exp_hr, "D3DXValidMesh test case %d failed. " +- "Got %x\n, expected %x\n", i, hr, tc[i].exp_hr); ++ "Got %x, expected %x\n", i, hr, tc[i].exp_hr); + + /* Note errors_and_warnings is deliberately not checked because that + * would require copying wast amounts of the text output. */ +@@ -10758,7 +10758,7 @@ static void test_optimize_faces(void) + tc[i].num_vertices, tc[i].indices_are_32bit, + face_remap); + ok(hr == D3D_OK, "D3DXOptimizeFaces test case %d failed. " +- "Got %x\n, expected D3D_OK\n", i, hr); ++ "Got %x, expected D3D_OK\n", i, hr); + + /* Compare face remap with expected face remap */ + for (j = 0; j < tc[i].num_faces; j++) +@@ -10776,14 +10776,14 @@ static void test_optimize_faces(void) + tc[0].num_vertices, tc[0].indices_are_32bit, + NULL); + ok(hr == D3DERR_INVALIDCALL, "D3DXOptimizeFaces passed NULL face_remap " +- "pointer. Got %x\n, expected D3DERR_INVALIDCALL\n", hr); ++ "pointer. Got %x, expected D3DERR_INVALIDCALL\n", hr); + + /* Number of faces must be smaller than 2^15 */ + hr = D3DXOptimizeFaces(tc[0].indices, 2 << 15, + tc[0].num_vertices, FALSE, + &smallest_face_remap); + ok(hr == D3DERR_INVALIDCALL, "D3DXOptimizeFaces should not accept 2^15 " +- "faces when using 16-bit indices. Got %x\n, expected D3DERR_INVALIDCALL\n", hr); ++ "faces when using 16-bit indices. Got %x, expected D3DERR_INVALIDCALL\n", hr); + } + + static HRESULT clear_normals(ID3DXMesh *mesh) +-- +2.13.1 + diff --git a/patches/d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch b/patches/d3dx9_36-D3DXOptimizeVertices/0002-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch similarity index 100% rename from patches/d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch rename to patches/d3dx9_36-D3DXOptimizeVertices/0002-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index e86f8958..d9b4f3e6 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -3838,8 +3838,10 @@ fi # | dlls/d3dx9_42/d3dx9_42.spec, dlls/d3dx9_43/d3dx9_43.spec # | if test "$enable_d3dx9_36_D3DXOptimizeVertices" -eq 1; then - patch_apply d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch + patch_apply d3dx9_36-D3DXOptimizeVertices/0001-d3dx9_36-tests-Remove-useless-n-within-some-ok-messa.patch + patch_apply d3dx9_36-D3DXOptimizeVertices/0002-d3dx9_36-Add-semi-stub-for-D3DXOptimizeVertices.patch ( + printf '%s\n' '+ { "Christian Costa", "d3dx9_36/tests: Remove useless \\n within some ok messages.", 1 },'; printf '%s\n' '+ { "Christian Costa", "d3dx9_36: Add semi-stub for D3DXOptimizeVertices.", 1 },'; ) >> "$patchlist" fi