mirror of
https://github.com/perlbot/perlbuut
synced 2025-06-07 16:15:39 -04:00
Setup more modules in eval
This commit is contained in:
parent
ae81c8dff8
commit
b4ef3b5197
3 changed files with 5 additions and 4 deletions
1
cpanfile
1
cpanfile
|
@ -67,3 +67,4 @@ requires 'Math::BigFloat' => 0;
|
|||
requires 'Math::BigRat' => 0;
|
||||
requires 'indirect' => 0;
|
||||
requires 'Moo' => 0;
|
||||
requires 'autovivification' => 0;
|
||||
|
|
|
@ -61,8 +61,8 @@ warn "Spawning Eval: $args->{code}\n";
|
|||
|
||||
$wheel->put( $args->{code} );
|
||||
|
||||
warn "Adding delay for 12 seconds: ", $wheel->ID;
|
||||
$kernel->delay_set( timeout => 12, $wheel->ID );
|
||||
warn "Adding delay for 30 seconds: ", $wheel->ID;
|
||||
$kernel->delay_set( timeout => 30, $wheel->ID );
|
||||
}
|
||||
|
||||
sub timeout {
|
||||
|
|
|
@ -167,7 +167,7 @@ use Storable qw/nfreeze/; nfreeze([]); #Preload Nfreeze since it's loaded on dem
|
|||
my $code = do { local $/; <STDIN> };
|
||||
|
||||
# Kill @INC to shorten errors;
|
||||
@INC = ();
|
||||
@INC = ('.');
|
||||
|
||||
# Close every other filehandle we may have open
|
||||
# this is probably legacy code at this point since it was used
|
||||
|
@ -299,7 +299,7 @@ use Storable qw/nfreeze/; nfreeze([]); #Preload Nfreeze since it's loaded on dem
|
|||
sub perl_code {
|
||||
my( $code ) = @_;
|
||||
local $@;
|
||||
local @INC;
|
||||
local @INC = ('.');
|
||||
|
||||
local $_;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue