The only solution I have found involves maintaining a list of handles in the main thread and dropping them after the worker thread indicates it is done
I think this is exactly the way to go if you need to pass file descriptor numbers around for some reason. If you don't want $c to go out of scope, just keep it around for as long as needed.
In reply to Re: Preventing IO::Handles from closing on destruction
by Eliya
in thread Preventing IO::Handles from closing on destruction
by exaethier
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |