0ad/PrepareZoneForGC.patch
Stefan Brüns 8b8674daba Accepting request 944820 from home:simonpuchert
- Make 0ad compatible with Tumbleweed's version of mozjs78:
  * no-version-check.patch: Disable the minor version check. This
    is required for a successful build using mozjs78 > 78.6.0.
  * PrepareZoneForGC.patch: This function got an additional
    parameter, change its usage accordingly. (boo#1187732)

OBS-URL: https://build.opensuse.org/request/show/944820
OBS-URL: https://build.opensuse.org/package/show/games/0ad?expand=0&rev=112
2022-01-09 18:09:21 +00:00

20 lines
887 B
Diff

diff -Nur 0ad-0.0.25b-alpha/source/scriptinterface/ScriptContext.cpp 0ad-0.0.25b-alpha-patched/source/scriptinterface/ScriptContext.cpp
--- 0ad-0.0.25b-alpha/source/scriptinterface/ScriptContext.cpp 2021-07-27 23:56:58.000000000 +0200
+++ 0ad-0.0.25b-alpha-patched/source/scriptinterface/ScriptContext.cpp 2021-12-30 16:58:57.749562521 +0100
@@ -143,7 +143,7 @@
// Schedule the zone for GC, which will destroy the realm.
if (JS::IsIncrementalGCInProgress(m_cx))
JS::FinishIncrementalGC(m_cx, JS::GCReason::API);
- JS::PrepareZoneForGC(js::GetRealmZone(realm));
+ JS::PrepareZoneForGC(m_cx, js::GetRealmZone(realm));
m_Realms.remove(realm);
}
@@ -261,5 +261,5 @@
void ScriptContext::PrepareZonesForIncrementalGC() const
{
for (JS::Realm* const& realm : m_Realms)
- JS::PrepareZoneForGC(js::GetRealmZone(realm));
+ JS::PrepareZoneForGC(m_cx, js::GetRealmZone(realm));
}