mirror of
https://github.com/pragma-/pbot.git
synced 2025-01-23 02:24:25 +01:00
Properly pass date to default VM languages
This commit is contained in:
parent
6fb1c3a142
commit
9608cac9cb
@ -45,8 +45,7 @@ sub preprocess {
|
||||
close $fh;
|
||||
|
||||
print "Executing [$self->{cmdline}] without print_last_statement\n";
|
||||
my ($retval, $result) = $self->execute(60, $self->{cmdline});
|
||||
|
||||
my ($retval, $result) = $self->execute(60, "bash -c \"date -s \@$self->{date} > /dev/null; ulimit -t 5; $self->{cmdline}\"");
|
||||
$self->{output} = $result;
|
||||
$self->{error} = $retval;
|
||||
|
||||
@ -57,7 +56,7 @@ sub preprocess {
|
||||
close $fh;
|
||||
|
||||
print "Executing [$self->{cmdline}] with print_last_statement\n";
|
||||
$self->execute(60, $self->{cmdline});
|
||||
my ($retval, $result) = $self->execute(60, "bash -c \"date -s \@$self->{date} > /dev/null; ulimit -t 5; $self->{cmdline}\"");
|
||||
}
|
||||
} else {
|
||||
open(my $fh, '>', $self->{sourcefile}) or die $!;
|
||||
@ -65,8 +64,7 @@ sub preprocess {
|
||||
close $fh;
|
||||
|
||||
print "Executing [$self->{cmdline}]\n";
|
||||
my ($retval, $result) = $self->execute(60, $self->{cmdline});
|
||||
|
||||
my ($retval, $result) = $self->execute(60, "bash -c \"date -s \@$self->{date} > /dev/null; ulimit -t 5; $self->{cmdline}\"");
|
||||
$self->{output} = $result;
|
||||
$self->{error} = $retval;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user