Reputation: 5124
I have a thread handle A which I got using OpenThread
.
Later in my program I need to use OpenThread
again on the same thread and to get its handle again, let's call it handle B.
Looking at the "watch" window, I can see that A != B.
When the thread dies I want to close its handle.
Would it be enough to close just handle A or just handle B? or do I need to close all the handles?
Can I ask OpenThread
to give me a handle that I already got from it before, or will it always give me new handles?
Upvotes: 0
Views: 332
Reputation: 71889
You have to close every handle. There is no way to get an existing handle from OpenThread, it will always create a new handle.
However, your problem description suggests that there is a deeper architectural problem here. Why do you want to do this?
Upvotes: 3