about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2019-09-17 08:48:00 +0000
committerEric Wong <e@80x24.org>2019-09-17 08:48:00 +0000
commit96ada3cfad29ff7d1ab2be2474235fc998c239e0 (patch)
tree6cd7cbce3524e4eec8ba9cb39dafedda4df75c87
parentb93664a04b041260b4e46aeeb92a521e7abd7c75 (diff)
downloadpublic-inbox-96ada3cfad29ff7d1ab2be2474235fc998c239e0.tar.gz
Actually do the redirect properly
-rw-r--r--t/httpd-corner.t5
1 files changed, 2 insertions, 3 deletions
diff --git a/t/httpd-corner.t b/t/httpd-corner.t
index c6f78dde..4077a6d1 100644
--- a/t/httpd-corner.t
+++ b/t/httpd-corner.t
@@ -32,8 +32,7 @@ my $psgi = "./t/httpd-corner.psgi";
 my $sock = tcp_server();
 
 # make sure stdin is not a pipe for lsof test to check for leaking pipes
-open(my $null, '<', '/dev/null') or die 'no /dev/null: $!';
-my $rdr = { 0 => fileno($null) };
+open(STDIN, '<', '/dev/null') or die 'no /dev/null: $!';
 
 # Make sure we don't clobber socket options set by systemd or similar
 # using socket activation:
@@ -61,7 +60,7 @@ END { kill 'TERM', $pid if defined $pid };
 my $spawn_httpd = sub {
         my (@args) = @_;
         my $cmd = [ $httpd, @args, "--stdout=$out", "--stderr=$err", $psgi ];
-        $pid = spawn_listener(undef, $cmd, [ $sock, $unix ], $rdr);
+        $pid = spawn_listener(undef, $cmd, [ $sock, $unix ]);
         ok(defined $pid, 'forked httpd process successfully');
 };