kaldor has asked for the wisdom of the Perl Monks concerning the following question:
my $cmd = "tail -f $0"; open(my $fh, "$cmd |") or die "cannot open pipe: $!"; while (<$fh>) { print; }
Since the child process is properly killed when run on MacOS, I think it's a Windows specific issue (related to not-being-posix and having different signals/process/fork). An explanation would be welcome.
Then, how should I fix it? By trapping signal(s) and killing it manually?
Thanks.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Zombie process after open pipe and SIGINT on Windows
by karlgoethebier (Abbot) on Jan 15, 2023 at 22:42 UTC | |
by kaldor (Beadle) on Jan 24, 2023 at 19:45 UTC | |
|
Re: Zombie process after open pipe and SIGINT on Windows
by kcott (Archbishop) on Jan 15, 2023 at 15:09 UTC | |
by kaldor (Beadle) on Jan 24, 2023 at 19:50 UTC | |
|
Re: Zombie process after open pipe and SIGINT on Windows
by Anonymous Monk on Jan 15, 2023 at 13:55 UTC | |
by Anonymous Monk on Jan 15, 2023 at 14:16 UTC | |
|
Re: Zombie process after open pipe and SIGINT on Windows
by kaldor (Beadle) on Jan 15, 2023 at 10:57 UTC | |
by afoken (Chancellor) on Jan 15, 2023 at 12:05 UTC | |
by kaldor (Beadle) on Jan 24, 2023 at 20:11 UTC |