use F<> in perlrepository.pod consistently and remove one needless whitespace
[p5sagit/p5-mst-13.2.git] / pod / perlipc.pod
index f027d23..416ded5 100644 (file)
@@ -119,14 +119,14 @@ handlers:
 But that will be problematic for the more complicated handlers that need
 to reinstall themselves.  Because Perl's signal mechanism is currently
 based on the signal(3) function from the C library, you may sometimes be so
-misfortunate as to run on systems where that function is "broken", that
+unfortunate as to run on systems where that function is "broken", that
 is, it behaves in the old unreliable SysV way rather than the newer, more
 reasonable BSD and POSIX fashion.  So you'll see defensive people writing
 signal handlers like this:
 
     sub REAPER {
        $waitedpid = wait;
-       # loathe sysV: it makes us not only reinstate
+       # loathe SysV: it makes us not only reinstate
        # the handler, but place it after the wait
        $SIG{CHLD} = \&REAPER;
     }
@@ -145,7 +145,7 @@ or better still:
         while (($child = waitpid(-1,WNOHANG)) > 0) {
            $Kid_Status{$child} = $?;
        }
-       $SIG{CHLD} = \&REAPER;  # still loathe sysV
+       $SIG{CHLD} = \&REAPER;  # still loathe SysV
     }
     $SIG{CHLD} = \&REAPER;
     # do something that forks...
@@ -536,7 +536,7 @@ output doesn't wind up on the user's terminal).
                                or die "Can't write to /dev/null: $!";
        defined(my $pid = fork) or die "Can't fork: $!";
        exit if $pid;
-       setsid                  or die "Can't start a new session: $!";
+       die "Can't start a new session: $!" if setsid == -1;
        open STDERR, '>&STDOUT' or die "Can't dup stdout: $!";
     }
 
@@ -581,7 +581,7 @@ you opened whatever your kid writes to his STDOUT.
        open (FILE, "> /safe/file")
            || die "can't open /safe/file: $!";
        while (<STDIN>) {
-           print FILE; # child's STDIN is parent's KID
+           print FILE; # child's STDIN is parent's KID_TO_WRITE
        }
        exit;  # don't forget this
     }
@@ -933,7 +933,7 @@ go back to service a new client.
         while ((my $pid = waitpid(-1,WNOHANG)) > 0 && WIFEXITED($?)) {
             logmsg "reaped $waitedpid" . ($? ? " with exit $?" : '');
         }
-        $SIG{CHLD} = \&REAPER;  # loathe sysV
+        $SIG{CHLD} = \&REAPER;  # loathe SysV
     }
 
     $SIG{CHLD} = \&REAPER;
@@ -1115,7 +1115,7 @@ to be on the localhost, and thus everything works right.
         while (($waitedpid = waitpid(-1,WNOHANG)) > 0) {
            logmsg "reaped $waitedpid" . ($? ? " with exit $?" : '');
        }
-       $SIG{CHLD} = \&REAPER;  # loathe sysV
+       $SIG{CHLD} = \&REAPER;  # loathe SysV
     }
 
     $SIG{CHLD} = \&REAPER;