[Lldb-commits] [lldb] [LLDB][Windows]: Don't pass duplicate HANDLEs to CreateProcess (PR #165281)
Charles Zablit via lldb-commits
lldb-commits at lists.llvm.org
Thu Oct 30 10:07:05 PDT 2025
charles-zablit wrote:
> There, you don’t see the actual error message though. Locally I’ve reproduced it too - it seems the failure isn’t deterministic though:
My guess is that the order of the handles matters, and using an `unordered_set` shuffles the handles. The previous approach with `std::sort` and `std::unique` would also fail.
I suggest using a vector and checking if the value already exists before inserting. The vector will always have less than 10 values so there is no performance issues with an O(n) search.
https://github.com/llvm/llvm-project/pull/165281
More information about the lldb-commits
mailing list