would like to know if there is a way of killing all the "child-threads" on Windows and keep the main thread still alive.
As I tried to explain above, not unless you can get access to the real process ids.
The only ways I know how to do that is to use the forking open:
my $pid = open my fh, "/path/to/the/exe args |" ...;
or the asynchronous spawn (
my $pid = system 1, '/path/to/the/exe args';
rather than fork & exec.
Neither of which maps particularly well onto the fork & exec idioms typical of *nix code.
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
|