]> Sergey Matveev's repositories - public-inbox.git/commitdiff
http: don't pass extra args to PublicInbox::DS::close
authorEric Wong <e@80x24.org>
Mon, 24 Jun 2019 02:52:28 +0000 (02:52 +0000)
committerEric Wong <e@80x24.org>
Mon, 24 Jun 2019 05:26:26 +0000 (05:26 +0000)
YAGNI

Followup-to: commit 30ab5cf82b9d47242640f748a0f9a088ca783e32
("ds: reduce Errno imports and drop ->close reason")

lib/PublicInbox/HTTP.pm
lib/PublicInbox/HTTPD/Async.pm

index 9497205488d4f5c1628470bbfe1312163deecaa2..c81aeacd172daf245c3101de98ab3c92be072f06 100644 (file)
@@ -438,7 +438,7 @@ sub quit {
 }
 
 sub close {
-       my $self = shift;
+       my $self = $_[0];
        if (my $env = delete $self->{env}) {
                delete $env->{'psgix.io'}; # prevent circular references
        }
@@ -447,7 +447,7 @@ sub close {
                eval { $forward->close };
                err($self, "forward ->close error: $@") if $@;
        }
-       $self->SUPER::close(@_);
+       $self->SUPER::close; # PublicInbox::DS::close
 }
 
 # for graceful shutdown in PublicInbox::Daemon:
index bec4933712cf8d240638bfd4db7aa67c6fc970cb..e6df58eb5c348edabf2b106ecb01484133171202 100644 (file)
@@ -80,9 +80,9 @@ sub async_pass {
 sub event_step { $_[0]->{cb}->(@_) }
 
 sub close {
-       my $self = shift;
+       my $self = $_[0];
        delete $self->{cb};
-       $self->SUPER::close(@_);
+       $self->SUPER::close;
 
        # we defer this to the next timer loop since close is deferred
        if (my $cleanup = delete $self->{cleanup}) {