about summary refs log tree commit homepage
path: root/lib
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2015-09-24 03:37:18 +0000
committerEric Wong <e@80x24.org>2015-09-24 06:58:31 +0000
commit812b9991ac21cbba7d9e60cb5a9e06a9fb69351d (patch)
tree018f5f6800c56689aed245eaff86c5ea9b3c30fb /lib
parent5e3247dc8d3844f2771dba6b5d316089f49ff40e (diff)
downloadpublic-inbox-812b9991ac21cbba7d9e60cb5a9e06a9fb69351d.tar.gz
This is better encapsulated and hopefully more readable.
While we're at it, check for being inside a long response, too.
Diffstat (limited to 'lib')
-rw-r--r--lib/PublicInbox/NNTP.pm5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/PublicInbox/NNTP.pm b/lib/PublicInbox/NNTP.pm
index 0d0de976..52d6a64c 100644
--- a/lib/PublicInbox/NNTP.pm
+++ b/lib/PublicInbox/NNTP.pm
@@ -919,4 +919,9 @@ sub watch_read {
         $rv;
 }
 
+sub busy () {
+        my ($self) = @_;
+        ($self->{rbuf} ne '' || $self->{long_res} || $self->{write_buf_size});
+}
+
 1;