From 510ecd9293760078a412b6b1cf90b3acf2a88e30 Mon Sep 17 00:00:00 2001 From: Swung0x48 Date: Sun, 6 Sep 2026 02:31:56 -0400 Subject: [PATCH] [Fix] (Impl): move the DeleteSync fill of the orphan sweep inside its null-entry guard - D7 says a verb whose table entry is null never bumps the serial; the sweep's fill sat before `if (backendDeleteSync && syncObject->backendHandle)`, so a backend without DeleteSync, or a sync without a backend handle, bumped once per orphan with nothing reading the fill. - The sibling sweep in GL_Query.cpp (DeleteBackendQuery) already fills inside its guard; this makes the two the same shape and leaves the declared list of guarded-expression sites at nine. - Pull build unchanged: MGP_FILL is ((void)0) there. --- MobileGL/MG_Impl/GLImpl/Sync/GL_Sync.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MobileGL/MG_Impl/GLImpl/Sync/GL_Sync.cpp b/MobileGL/MG_Impl/GLImpl/Sync/GL_Sync.cpp index 6a818aad..60813976 100644 --- a/MobileGL/MG_Impl/GLImpl/Sync/GL_Sync.cpp +++ b/MobileGL/MG_Impl/GLImpl/Sync/GL_Sync.cpp @@ -232,8 +232,8 @@ namespace MobileGL::MG_Impl::GLImpl { // the function table itself is cleared. const auto backendDeleteSync = MG_Backend::gBackendFunctionsTable.GL.DeleteSync; for (const auto& [_, syncObject] : orphans) { - MGP_FILL(DeleteSync); if (backendDeleteSync && syncObject->backendHandle) { + MGP_FILL(DeleteSync); backendDeleteSync(syncObject->backendHandle); } delete syncObject;