summaryrefslogtreecommitdiff
path: root/lib/IPC
diff options
context:
space:
mode:
authorPerl 5 Porters <perl5-porters@africa.nicoh.com>1996-02-02 18:52:27 -0800
committerLarry Wall <lwall@sems.com>1996-02-02 18:52:27 -0800
commitc07a80fdfe3926b5eb0585b674aa5d1f57b32ade (patch)
tree6d56135571eb9ea6635748469bdaf72ad481247a /lib/IPC
parent91b7def858c29dac014df40946a128c06b3aa2ed (diff)
downloadperl-c07a80fdfe3926b5eb0585b674aa5d1f57b32ade.tar.gz
perl5.002beta3
[editor's note: no patch file was found for this release, so no fine-grained changes] I can't find the password for our ftp server, so I had to drop it into ftp://ftp.sems.com/pub/incoming/perl5.002b3.tar.gz, which is a drop directory you can't ls. The current plan is that Andy is gonna whack on this a little more, and then release a gamma in a few days when he's happy with it. So don't get carried away. This is now *late* beta. In other words, have less than the appropriate amount of fun. :-) Larry
Diffstat (limited to 'lib/IPC')
-rw-r--r--lib/IPC/Open2.pm4
-rw-r--r--lib/IPC/Open3.pm6
2 files changed, 5 insertions, 5 deletions
diff --git a/lib/IPC/Open2.pm b/lib/IPC/Open2.pm
index 1ac963ab6b..243412ef09 100644
--- a/lib/IPC/Open2.pm
+++ b/lib/IPC/Open2.pm
@@ -96,8 +96,8 @@ sub open2 {
open(STDIN, "<&$kid_rdr");
open(STDOUT, ">&$kid_wtr");
warn "execing @cmd\n" if $debug;
- exec @cmd;
- croak "open2: exec of @cmd failed";
+ exec @cmd
+ or croak "open2: exec of @cmd failed";
}
close $kid_rdr; close $kid_wtr;
select((select($dad_wtr), $| = 1)[0]); # unbuffer pipe
diff --git a/lib/IPC/Open3.pm b/lib/IPC/Open3.pm
index 5bc757c344..dbf5562028 100644
--- a/lib/IPC/Open3.pm
+++ b/lib/IPC/Open3.pm
@@ -102,7 +102,7 @@ sub open3 {
}
if (($kidpid = fork) < 0) {
- croak "open2: fork failed: $!";
+ croak "open3: fork failed: $!";
} elsif ($kidpid == 0) {
if ($dup_wtr) {
open(STDIN, "<&$dad_wtr") if (fileno(STDIN) != fileno($dad_wtr));
@@ -128,8 +128,8 @@ sub open3 {
open(STDERR, ">&STDOUT") if (fileno(STDERR) != fileno(STDOUT));
}
local($")=(" ");
- exec @cmd;
- croak "open2: exec of @cmd failed";
+ exec @cmd
+ or croak "open3: exec of @cmd failed";
}
close $kid_rdr; close $kid_wtr; close $kid_err;