-
Bug
-
Resolution: Fixed
-
P2
-
None
-
repo-panama
While no test is showing sign of failures (even under extra stress), it seems like the code which manages shared resource scope lists has at least a conceptual issue: the code always performs a "compareAndExchange", using the "previous" list head as witness and the new cleanup action as the actual value. If the witness is the CLOSED_LIST singleton (which means the list is about to be cleaned up), the replacement still takes place, meaning that the head of the list can potentially go from CLOSED_LIST to something else, possibly in the middle of a cleanup.