FBA: Fix race when unloading discoverable projects on close
- Dominant language
- C#
- Stars
- 20.7k
- Forks
- 4.3k
- PR merge metrics
- PR metrics pending
Description
Random thought: there's a race here. Consider the case where:
1. We discover the file exists. We start it loading.
2. While it's still in the primordial state, we open the file.
3. And then we close it really quickly.
The file is still in misc files in the primordial state, right? And we'll unload?
(I'm not sure if this is a practical case since that's a really tricky set of timing things to do...which probably means it happens [next Tuesday](https://learn.microsoft.com/en-us/archive/blogs/larryosterman/one-in-a-million-is-next-tuesday) and maybe we should think about this a bit. But I'm willing to pass on it for now.)
_Originally posted by @jasonmalinowski in https://github.com/dotnet/roslyn/pull/82863#discussion_r3019585131_
Contributor guide
Assessment
This issue has not been assessed yet.