This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
suppress error messages from the shell when probing Storable limits
authorTony Cook <tony@develop-help.com>
Mon, 19 Feb 2018 23:10:34 +0000 (10:10 +1100)
committerTony Cook <tony@develop-help.com>
Mon, 26 Feb 2018 04:16:05 +0000 (15:16 +1100)
dist/Storable/stacksize

index a698726..5ea40da 100644 (file)
@@ -4,6 +4,7 @@
 
 use Config;
 use Cwd;
+use File::Spec;
 use strict;
 
 my $fn = "lib/Storable/Limit.pm";
@@ -123,6 +124,10 @@ sub bad {
     return $j;
 }
 
+unless ($ENV{STORABLE_NOISY}) {
+    # suppress Segmentation fault messages
+    open STDERR, ">", File::Spec->devnull;
+}
 while (!$found) {
     my $cmd = cmd($n, '$t=[$t]', 'recursion_limit');
     #print "$cmd\n" unless $QUIET;