]> Sergey Matveev's repositories - public-inbox.git/commitdiff
httpd: fill in missing Danga::Socket callbacks
authorEric Wong <e@80x24.org>
Thu, 25 Feb 2016 05:26:23 +0000 (05:26 +0000)
committerEric Wong <e@80x24.org>
Thu, 25 Feb 2016 05:26:40 +0000 (05:26 +0000)
Danga::Socket will die on us if we hit the base implementations.

lib/PublicInbox/HTTP.pm
public-inbox-httpd

index a5149ac2b85bdfc9d79f8f1e100f8b6092a76ed6..f65dedaae2c5a64e3935b7ef0304b4560387a7b4 100644 (file)
@@ -331,4 +331,9 @@ sub quit {
        $self->close;
 }
 
+# callbacks for Danga::Socket
+
+sub event_hup { $_[0]->close }
+sub event_err { $_[0]->close }
+
 1;
index 0c1e24cbc1de07178b21df2cb142fb2c4a9c7754..772333e8b0a49a084f14853c6ae9c5a27796473f 100644 (file)
@@ -72,6 +72,7 @@ sub new {
 
 sub event_read { $_[0]->{cb}->() }
 sub event_hup { $_[0]->{cb}->() }
+sub event_err { $_[0]->{cb}->() }
 sub sysread { shift->{sock}->sysread(@_) }
 
 1;