about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2022-07-23 04:41:49 +0000
committerEric Wong <e@80x24.org>2022-07-23 14:22:30 +0000
commit0f432191082f889c4296351e356c4abaf8cc7a28 (patch)
treee12e12de2cbc0e22e75d2f08a9a156414c814c5a
parentb5371f1053676a4a551140739582070df773dc9c (diff)
downloadpublic-inbox-0f432191082f889c4296351e356c4abaf8cc7a28.tar.gz
ds: move no-op ->zflush to common base class
More deduplication, and POP3 never needed it.
-rw-r--r--lib/PublicInbox/DS.pm2
-rw-r--r--lib/PublicInbox/IMAP.pm2
-rw-r--r--lib/PublicInbox/NNTP.pm2
-rw-r--r--lib/PublicInbox/POP3.pm2
4 files changed, 2 insertions, 6 deletions
diff --git a/lib/PublicInbox/DS.pm b/lib/PublicInbox/DS.pm
index 79f7046f..daef9d89 100644
--- a/lib/PublicInbox/DS.pm
+++ b/lib/PublicInbox/DS.pm
@@ -648,6 +648,8 @@ sub shutdn ($) {
     }
 }
 
+sub zflush {} # overridden by NNTPdeflate and IMAPdeflate
+
 sub dwaitpid ($;$$) {
         my ($pid, $cb, $arg) = @_;
         if ($in_loop) {
diff --git a/lib/PublicInbox/IMAP.pm b/lib/PublicInbox/IMAP.pm
index 89a278c1..f4b08eee 100644
--- a/lib/PublicInbox/IMAP.pm
+++ b/lib/PublicInbox/IMAP.pm
@@ -1271,8 +1271,6 @@ sub event_step {
 
 sub compressed { undef }
 
-sub zflush {} # overridden by IMAPdeflate
-
 # RFC 4978
 sub cmd_compress ($$$) {
         my ($self, $tag, $alg) = @_;
diff --git a/lib/PublicInbox/NNTP.pm b/lib/PublicInbox/NNTP.pm
index 533a0c59..f0ee11cb 100644
--- a/lib/PublicInbox/NNTP.pm
+++ b/lib/PublicInbox/NNTP.pm
@@ -968,8 +968,6 @@ sub cmd_compress ($$) {
         undef
 }
 
-sub zflush {} # overridden by NNTPdeflate
-
 sub cmd_xpath ($$) {
         my ($self, $mid) = @_;
         return r501 unless $mid =~ $ONE_MSGID;
diff --git a/lib/PublicInbox/POP3.pm b/lib/PublicInbox/POP3.pm
index c368615d..fcea4bb9 100644
--- a/lib/PublicInbox/POP3.pm
+++ b/lib/PublicInbox/POP3.pm
@@ -55,8 +55,6 @@ sub out ($$;@) {
         printf { $self->{pop3d}->{out} } $fmt."\n", @args;
 }
 
-sub zflush {} # noop
-
 sub requeue_once ($) {
         my ($self) = @_;
         # COMPRESS users all share the same DEFLATE context.