https://bz.apache.org/bugzilla/show_bug.cgi?id=69592
--- Comment #2 from abernal <[email protected]> --- Update: an independent review caught a real concurrency bug in the first version of the fix, specific to LuaScope server. ap_lua_release_state() for that scope hands the parent VM back to its apr_reslist pool, making it available for another thread to acquire immediately; the original patch called lua_pop(parent, 1) after that release, so a second thread could acquire the same parent and push its own coroutine onto it before the first thread's pop ran, causing the pop to remove the second thread's coroutine instead of its own. Reproduced this for real with temporary logging and an injected delay between release and pop, 2 concurrent requests against LuaScope server 1 1 (forcing both threads to share one VM): saw the exact predicted cross-removal every time. Moving lua_pop() before ap_lua_release_state(), now in PR https://github.com/apache/httpd/pull/1044, closes it: the same forced-delay scenario against the corrected ordering shows clean, fully serialized acquire/push/pop/release per request. The existing regression test and the rest of the modules/lua suite (61 tests) still pass with the corrected ordering. -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
