From 1aff1f07b5f6acc661aefc0d6fc1d744e6f8025d Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 25 Dec 2016 06:39:13 +0000 Subject: githttpbackend: minor readability improvement Use a more meaningful variable name for the Qspawn object, since this module is the reference for its use. --- lib/PublicInbox/GitHTTPBackend.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib') diff --git a/lib/PublicInbox/GitHTTPBackend.pm b/lib/PublicInbox/GitHTTPBackend.pm index a069fd94..86b8ebcc 100644 --- a/lib/PublicInbox/GitHTTPBackend.pm +++ b/lib/PublicInbox/GitHTTPBackend.pm @@ -206,11 +206,11 @@ sub serve_smart { } $env{GIT_HTTP_EXPORT_ALL} = '1'; $env{PATH_TRANSLATED} = "$git_dir/$path"; - my %rdr = ( 0 => fileno($in) ); - my $x = PublicInbox::Qspawn->new([qw(git http-backend)], \%env, \%rdr); + my $rdr = { 0 => fileno($in) }; + my $qsp = PublicInbox::Qspawn->new([qw(git http-backend)], \%env, $rdr); my ($fh, $rpipe); my $end = sub { - if (my $err = $x->finish) { + if (my $err = $qsp->finish) { err($env, "git http-backend ($git_dir): $err"); } $fh->close if $fh; # async-only @@ -258,7 +258,7 @@ sub serve_smart { # holding the input here is a waste of FDs and memory $env->{'psgi.input'} = undef; - $x->start($limiter, sub { # may run later, much later... + $qsp->start($limiter, sub { # may run later, much later... ($rpipe) = @_; $in = undef; if ($async) { -- cgit v1.2.3-24-ge0c7