in reply to Preventing IO::Handles from closing on destruction
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.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Preventing IO::Handles from closing on destruction
by exaethier (Initiate) on Nov 04, 2011 at 15:36 UTC | |
by Eliya (Vicar) on Nov 04, 2011 at 15:55 UTC | |
by exaethier (Initiate) on Nov 04, 2011 at 18:30 UTC |