Files
EVEngine/src/modules/thread
西风逍遥游 fb42efcc5f fix(thread): close JobSystem releaseDependents use-after-free
ASan (Linux CI) caught a heap-use-after-free in
JobSystemThreadPool::releaseDependents (voxel.world.cross_chunk_seam_culled):
completeJob set completionDone=true and released the mutex, then iterated
job->dependents. A waiter could acquire the mutex in between, see
completionDone, return from wait() and delete the heap job (owned by the
caller), freeing the dependents vector mid-iteration.

Move releaseDependents inside the same critical section and set
completionDone last, so no waiter can observe completion before the
dependents are released. Add a stress regression test that waits on a
completed child and deletes it immediately, 200 iterations.
2026-08-22 12:25:25 +08:00
..