From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-4.2 required=3.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, T_SCC_BODY_TEXT_LINE shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id 2A13D1F6AB for ; Sat, 10 Sep 2022 08:18:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=80x24.org; s=selector1; t=1662797938; bh=lz3BX6omCHmzFNmkad+4Lp8Qs/yYxUJvUmMQ7GoMRqM=; h=From:To:Subject:Date:In-Reply-To:References:From; b=zChuKSbHdHNn0N90GdMGuQjW6B5+TfRw+x+wwnkawiSOGafbxu1CQhF1d/6Ur7Z+N pEbc8LYpakWAXIQVfLuJ+ktJIzibJhdggPSoVbju09axIBT3428jGuwKazld8azb8L qvZuWRSca6QdAWIxge8DGergcbHlu03A/mUJsdLE= From: Eric Wong To: meta@public-inbox.org Subject: [PATCH 35/38] feed: new_html_i: switch from zmore to `print $zfh' Date: Sat, 10 Sep 2022 08:17:26 +0000 Message-Id: <20220910081729.2011934-36-e@80x24.org> In-Reply-To: <20220910081729.2011934-1-e@80x24.org> References: <20220910081729.2011934-1-e@80x24.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: eml_entry will enable zfh (PerlIO::scalar) buffering, anyways, so there's no point in calling ->zmore to compress small strings. The use of zfh for the skeleton is debatable, but probably of no consequence given html_footer will hit it, anyways. --- lib/PublicInbox/Feed.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/PublicInbox/Feed.pm b/lib/PublicInbox/Feed.pm index 56ca9886..affe0fb6 100644 --- a/lib/PublicInbox/Feed.pm +++ b/lib/PublicInbox/Feed.pm @@ -49,15 +49,15 @@ sub generate_html_index { sub new_html_i { my ($ctx, $eml) = @_; - $ctx->zmore($ctx->html_top) if exists $ctx->{-html_tip}; + print { $ctx->zfh } $ctx->html_top if exists $ctx->{-html_tip}; if ($eml) { $ctx->{smsg}->populate($eml) if !$ctx->{ibx}->{over}; return PublicInbox::View::eml_entry($ctx, $eml); } my $smsg = shift @{$ctx->{msgs}} or - $ctx->zmore(PublicInbox::View::pagination_footer( - $ctx, './new.html')); + print { $ctx->zfh } PublicInbox::View::pagination_footer( + $ctx, './new.html'); $smsg; }