This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6a06517
)
problem with exit in child process in BEGIN
author
Robin Barker
<rmbarker@cpan.org>
Wed, 9 Feb 2011 16:31:39 +0000
(16:31 +0000)
committer
Father Chrysostomos
<sprout@cpan.org>
Wed, 9 Feb 2011 17:17:31 +0000
(09:17 -0800)
pod/perlport.pod
patch
|
blob
|
blame
|
history
diff --git
a/pod/perlport.pod
b/pod/perlport.pod
index
04f2d0d
..
8450fc7
100644
(file)
--- a/
pod/perlport.pod
+++ b/
pod/perlport.pod
@@
-1632,6
+1632,13
@@
enabled, a generic number will be encoded in a method compatible with
the C library _POSIX_EXIT macro so that it can be decoded by other
programs, particularly ones written in C, like the GNV package. (VMS)
+C<exit()> resets file pointers, which is a problem when called
+from a child process (created by C<fork()>) in C<BEGIN>.
+A workaround is to use C<POSIX::_exit>. (Solaris)
+
+ exit unless $Config{archname} =~ /\bsolaris\b/;
+ require POSIX and POSIX::_exit(0);
+
=item fcntl
Not implemented. (Win32)