Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Previously, there was a case involving cache invalidation when the extension could be preloaded. Namely the following happened: 1) extension_check (outer) was called and found loaded = true. 2) While the extension_check was checking the state of the extension a cache invalidation callback happened. 3) The cache invalidation callback called extension_check (inner). 4) The inner extension_check loads the extension and sets loaded = true. 5) The outer extension_check also loads the extension after the cache invalidation callback returns. This happens because it never re-checks the value of loaded. This commit adds another check of loaded just before it is changed to prevent this situation.
- Loading branch information