From fb2b3b3c69b7aa7d2d7532c0d42ea2a4f87222a6 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Tue, 26 Jul 2022 09:14:17 +1000 Subject: [PATCH] Rebase against 889fe64d9f2e1a0d9a3660bbb94e0a9b74155827. --- patches/patchinstall.sh | 3 +- ...7-Add-helper-function-to-add-entries.patch | 20 ++++----- ...move-Entry-after-FAudio-Destroyed-ca.patch | 42 ------------------- staging/upstream-commit | 2 +- 4 files changed, 12 insertions(+), 55 deletions(-) delete mode 100644 patches/xactengine3_7-callbacks/0006-xactengine3_7-Remove-Entry-after-FAudio-Destroyed-ca.patch diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index ea5b8772..cc7e8a39 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -51,7 +51,7 @@ usage() # Get the upstream commit sha upstream_commit() { - echo "7b77b4e3b4ea732ed592ac15f000875f5d1f1daa" + echo "889fe64d9f2e1a0d9a3660bbb94e0a9b74155827" } # Show version information @@ -3898,7 +3898,6 @@ if test "$enable_xactengine3_7_callbacks" -eq 1; then patch_apply xactengine3_7-callbacks/0003-xactengine3_7-Map-IXACT3Cue-interfaces.patch patch_apply xactengine3_7-callbacks/0004-xactengine3_7-Map-IXACT3Wave-interfaces.patch patch_apply xactengine3_7-callbacks/0005-xactengine3_7-Implement-callback-for-supported-messa.patch - patch_apply xactengine3_7-callbacks/0006-xactengine3_7-Remove-Entry-after-FAudio-Destroyed-ca.patch fi if test "$enable_autoconf" -eq 1; then diff --git a/patches/xactengine3_7-callbacks/0001-xactengine3_7-Add-helper-function-to-add-entries.patch b/patches/xactengine3_7-callbacks/0001-xactengine3_7-Add-helper-function-to-add-entries.patch index 6841193e..936b9b0e 100644 --- a/patches/xactengine3_7-callbacks/0001-xactengine3_7-Add-helper-function-to-add-entries.patch +++ b/patches/xactengine3_7-callbacks/0001-xactengine3_7-Add-helper-function-to-add-entries.patch @@ -1,7 +1,7 @@ -From 5eaf6ecd797b085898e95c6710b6d47e805b7811 Mon Sep 17 00:00:00 2001 +From 740d92f0478b460ed176741cb6d98862d4d57e32 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Wed, 20 Jul 2022 11:32:36 +1000 -Subject: [PATCH 1/4] xactengine3_7: Add helper function to add entries +Subject: [PATCH] xactengine3_7: Add helper function to add entries Signed-off-by: Alistair Leslie-Hughes --- @@ -9,12 +9,12 @@ Signed-off-by: Alistair Leslie-Hughes 1 file changed, 33 insertions(+), 34 deletions(-) diff --git a/dlls/xactengine3_7/xact_dll.c b/dlls/xactengine3_7/xact_dll.c -index 7664328dbc4..421c509fcfa 100644 +index f450320a355..eb4020afec7 100644 --- a/dlls/xactengine3_7/xact_dll.c +++ b/dlls/xactengine3_7/xact_dll.c -@@ -88,6 +88,33 @@ typedef struct _XACT3EngineImpl { - CRITICAL_SECTION wb_wrapper_lookup_cs; - } XACT3EngineImpl; +@@ -113,6 +113,33 @@ static void wrapper_remove_entry(XACT3EngineImpl *engine, void *key) + } + } +static HRESULT wrapper_add_entry(XACT3EngineImpl *engine, void *fwb, void *xact) +{ @@ -46,7 +46,7 @@ index 7664328dbc4..421c509fcfa 100644 typedef struct _XACT3CueImpl { IXACT3Cue IXACT3Cue_iface; FACTCue *fact_cue; -@@ -1086,9 +1113,9 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *ifac +@@ -1092,9 +1119,9 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *ifac DWORD dwAllocAttributes, IXACT3WaveBank **ppWaveBank) { XACT3EngineImpl *This = impl_from_IXACT3Engine(iface); @@ -57,7 +57,7 @@ index 7664328dbc4..421c509fcfa 100644 UINT ret; TRACE("(%p)->(%p, %lu, 0x%lx, 0x%lx, %p)\n", This, pvBuffer, dwSize, dwFlags, -@@ -1110,28 +1137,14 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *ifac +@@ -1116,28 +1143,14 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *ifac return E_OUTOFMEMORY; } @@ -88,7 +88,7 @@ index 7664328dbc4..421c509fcfa 100644 wb->IXACT3WaveBank_iface.lpVtbl = &XACT3WaveBank_Vtbl; wb->fact_wavebank = fwb; -@@ -1149,11 +1162,11 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateStreamingWaveBank(IXACT3Engine *ifa +@@ -1155,11 +1168,11 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateStreamingWaveBank(IXACT3Engine *ifa { XACT3EngineImpl *This = impl_from_IXACT3Engine(iface); FACTStreamingParameters fakeParms; @@ -101,7 +101,7 @@ index 7664328dbc4..421c509fcfa 100644 TRACE("(%p)->(%p, %p)\n", This, pParms, ppWaveBank); -@@ -1183,28 +1196,14 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateStreamingWaveBank(IXACT3Engine *ifa +@@ -1189,28 +1202,14 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateStreamingWaveBank(IXACT3Engine *ifa return E_OUTOFMEMORY; } diff --git a/patches/xactengine3_7-callbacks/0006-xactengine3_7-Remove-Entry-after-FAudio-Destroyed-ca.patch b/patches/xactengine3_7-callbacks/0006-xactengine3_7-Remove-Entry-after-FAudio-Destroyed-ca.patch deleted file mode 100644 index f9ee3dee..00000000 --- a/patches/xactengine3_7-callbacks/0006-xactengine3_7-Remove-Entry-after-FAudio-Destroyed-ca.patch +++ /dev/null @@ -1,42 +0,0 @@ -From c2849dce7ff45f6c003198b43153c7e2c597c988 Mon Sep 17 00:00:00 2001 -From: Alistair Leslie-Hughes -Date: Fri, 22 Jul 2022 12:34:27 +1000 -Subject: [PATCH] xactengine3_7: Remove Entry after FAudio Destroyed call - -FACTWaveBank_Destroy will invoke the callback which we -attempt to lookup the wavebank. - -The callback must have a pointer, help states it isn't valid but still -points to the wavebank that was destroyed. ---- - dlls/xactengine3_7/xact_dll.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/dlls/xactengine3_7/xact_dll.c b/dlls/xactengine3_7/xact_dll.c -index 19c02036907..a72afcc18e1 100644 ---- a/dlls/xactengine3_7/xact_dll.c -+++ b/dlls/xactengine3_7/xact_dll.c -@@ -661,10 +661,11 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Destroy(IXACT3WaveBank *iface) - - TRACE("(%p)\n", This); - -+ hr = FACTWaveBank_Destroy(This->fact_wavebank); -+ - EnterCriticalSection(&This->engine->wb_wrapper_lookup_cs); - - entry = wine_rb_get(&This->engine->wb_wrapper_lookup, This->fact_wavebank); -- - if (!entry) - { - LeaveCriticalSection(&This->engine->wb_wrapper_lookup_cs); -@@ -681,7 +682,6 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Destroy(IXACT3WaveBank *iface) - HeapFree(GetProcessHeap(), 0, lookup); - } - -- hr = FACTWaveBank_Destroy(This->fact_wavebank); - HeapFree(GetProcessHeap(), 0, This); - return hr; - } --- -2.35.1 - diff --git a/staging/upstream-commit b/staging/upstream-commit index a6afc510..66fd06a0 100644 --- a/staging/upstream-commit +++ b/staging/upstream-commit @@ -1 +1 @@ -7b77b4e3b4ea732ed592ac15f000875f5d1f1daa +889fe64d9f2e1a0d9a3660bbb94e0a9b74155827