Change 20610 by [EMAIL PROTECTED] on 2003/08/11 06:37:13

        Integrate:
        [ 20607]
        Subject: Re: killing for vital signs [PATCH]
        From: "John P. Linderman" <[EMAIL PROTECTED]>
        Date: Sun, 10 Aug 2003 15:44:33 -0400 (EDT)
        Message-Id: <[EMAIL PROTECTED]>
        
        [ 20608]
        Explain the 'Wide character in print' a bit more.
        
        [ 20609]
        Subject: [perl #23273] warnings in Unicode::UCD
        From: Lukas Mai (via RT) <[EMAIL PROTECTED]>
        Date: 10 Aug 2003 22:37:41 -0000
        Message-ID: <[EMAIL PROTECTED]>

Affected files ...

... //depot/maint-5.8/perl/lib/Unicode/UCD.pm#5 integrate
... //depot/maint-5.8/perl/lib/Unicode/UCD.t#7 integrate
... //depot/maint-5.8/perl/pod/perldiag.pod#38 integrate
... //depot/maint-5.8/perl/pod/perlfunc.pod#37 integrate
... //depot/maint-5.8/perl/pod/perlipc.pod#9 integrate

Differences ...

==== //depot/maint-5.8/perl/lib/Unicode/UCD.pm#5 (text) ====
Index: perl/lib/Unicode/UCD.pm
--- perl/lib/Unicode/UCD.pm#4~20241~    Sun Jul 27 13:07:20 2003
+++ perl/lib/Unicode/UCD.pm     Sun Aug 10 23:37:13 2003
@@ -211,6 +211,7 @@
        use Search::Dict 1.02;
        if (look($UNICODEFH, "$hexk;", { xfrm => sub { $_[0] =~ /^([^;]+);(.+)/; 
sprintf "%06X;$2", hex($1) } } ) >= 0) {
            my $line = <$UNICODEFH>;
+           return unless defined $line;
            chomp $line;
            my %prop;
            @prop{qw(

==== //depot/maint-5.8/perl/lib/Unicode/UCD.t#7 (text) ====
Index: perl/lib/Unicode/UCD.t
--- perl/lib/Unicode/UCD.t#6~20241~     Sun Jul 27 13:07:20 2003
+++ perl/lib/Unicode/UCD.t      Sun Aug 10 23:37:13 2003
@@ -12,7 +12,7 @@
 use Unicode::UCD;
 use Test::More;
 
-BEGIN { plan tests => 178 };
+BEGIN { plan tests => 179 };
 
 use Unicode::UCD 'charinfo';
 
@@ -309,3 +309,6 @@
     is(@$r2, $n1, "modifying results should not mess up internal caches");
 }
 
+{
+       is(charinfo(0xdeadbeef), undef, "[perl #23273] warnings in Unicode::UCD");
+}
\ No newline at end of file

==== //depot/maint-5.8/perl/pod/perldiag.pod#38 (text) ====
Index: perl/pod/perldiag.pod
--- perl/pod/perldiag.pod#37~20522~     Wed Aug  6 06:29:26 2003
+++ perl/pod/perldiag.pod       Sun Aug 10 23:37:13 2003
@@ -4452,9 +4452,12 @@
 =item Wide character in %s
 
 (W utf8) Perl met a wide character (>255) when it wasn't expecting
-one.  This warning is by default on for I/O (like print) but can be
-turned off by C<no warnings 'utf8';>.  You are supposed to explicitly
-mark the filehandle with an encoding, see L<open> and L<perlfunc/binmode>.
+one.  This warning is by default on for I/O (like print).  The easiest
+way to quiet this warning is simply to add the C<:utf8> layer to the
+output, e.g. C<binmode STDOUT, ':utf8'>.  Another way to turn off the
+warning is to add C<no warnings 'utf8';> but that is often closer to
+cheating.  In general, you are supposed to explicitly mark the
+filehandle with an encoding, see L<open> and L<perlfunc/binmode>.
 
 =item Within []-length '%c' not allowed
 

==== //depot/maint-5.8/perl/pod/perlfunc.pod#37 (text) ====
Index: perl/pod/perlfunc.pod
--- perl/pod/perlfunc.pod#36~20522~     Wed Aug  6 06:29:26 2003
+++ perl/pod/perlfunc.pod       Sun Aug 10 23:37:13 2003
@@ -2381,7 +2381,7 @@
     kill 9, @goners;
 
 If SIGNAL is zero, no signal is sent to the process.  This is a
-useful way to check that the process is alive and hasn't changed
+useful way to check that a child process is alive and hasn't changed
 its UID.  See L<perlport> for notes on the portability of this
 construct.
 
@@ -2389,7 +2389,9 @@
 process groups instead of processes.  (On System V, a negative I<PROCESS>
 number will also kill process groups, but that's not portable.)  That
 means you usually want to use positive not negative signals.  You may also
-use a signal name in quotes.  See L<perlipc/"Signals"> for details.
+use a signal name in quotes.
+
+See L<perlipc/"Signals"> for more details.
 
 =item last LABEL
 

==== //depot/maint-5.8/perl/pod/perlipc.pod#9 (text) ====
Index: perl/pod/perlipc.pod
--- perl/pod/perlipc.pod#8~20181~       Wed Jul 23 06:12:38 2003
+++ perl/pod/perlipc.pod        Sun Aug 10 23:37:13 2003
@@ -95,11 +95,20 @@
     }
 
 Another interesting signal to send is signal number zero.  This doesn't
-actually affect another process, but instead checks whether it's alive
+actually affect a child process, but instead checks whether it's alive
 or has changed its UID.
 
     unless (kill 0 => $kid_pid) {
        warn "something wicked happened to $kid_pid";
+    }
+
+When directed at a process whose UID is not identical to that
+of the sending process, signal number zero may fail because
+you lack permission to send the signal, even though the process is alive.
+You may be able to determine the cause of failure using C<$!>.
+
+    unless (kill 0 => $pid or $! == $!{EPERM}) {
+       warn "$pid looks dead";
     }
 
 You might also want to employ anonymous functions for simple signal
End of Patch.

Reply via email to