diff options
author | Eric Wong <e@80x24.org> | 2019-03-12 01:47:59 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2019-04-04 09:13:58 +0000 |
commit | 07f770c321474751550c4d73c65c27b2b197ac35 (patch) | |
tree | 018ca8e4317dfc373ffa9082fbd732d5130f825d /t | |
parent | 7661a5732ebf4470339c1293b2ea32082af887be (diff) | |
download | public-inbox-07f770c321474751550c4d73c65c27b2b197ac35.tar.gz |
Our high-level config already treats single limits as a soft==hard limit for limiters; so stop handling that redundant in the low-level spawn() sub.
Diffstat (limited to 't')
-rw-r--r-- | t/spawn.t | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -100,7 +100,8 @@ SKIP: { my ($r, $w); pipe($r, $w) or die "pipe: $!"; my $cmd = ['sh', '-c', 'while true; do :; done']; - my $opt = { RLIMIT_CPU => [ 1, 1 ], RLIMIT_CORE => 0, 1 => fileno($w) }; + my $fd = fileno($w); + my $opt = { RLIMIT_CPU => [ 1, 1 ], RLIMIT_CORE => [ 0, 0 ], 1 => $fd }; my $pid = spawn($cmd, undef, $opt); close $w or die "close(w): $!"; my $rset = ''; |