From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id uEZeB+FclF4CPAAA0tVLHw (envelope-from ) for ; Mon, 13 Apr 2020 12:36:49 +0000 Received: from aspmx2.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id cCUNNeNclF4xYwAAbx9fmQ (envelope-from ) for ; Mon, 13 Apr 2020 12:36:51 +0000 Received: from arlo.cworth.org (arlo.cworth.org [50.126.95.6]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits)) (No client certificate requested) by aspmx2.migadu.com (Postfix) with ESMTPS id AD9016820EA for ; Mon, 13 Apr 2020 12:36:48 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id C81356DE13E7; Mon, 13 Apr 2020 05:36:41 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2CwXB3YoBt1I; Mon, 13 Apr 2020 05:36:41 -0700 (PDT) Received: from arlo.cworth.org (localhost [IPv6:::1]) by arlo.cworth.org (Postfix) with ESMTP id B2DCB6DE13BA; Mon, 13 Apr 2020 05:36:37 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 2B6816DE13BE for ; Mon, 13 Apr 2020 05:36:36 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LTi5xE43PANZ for ; Mon, 13 Apr 2020 05:36:35 -0700 (PDT) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by arlo.cworth.org (Postfix) with ESMTPS id 6D3656DE0EE7 for ; Mon, 13 Apr 2020 05:36:35 -0700 (PDT) Received: from remotemail by fethera.tethera.net with local (Exim 4.92) (envelope-from ) id 1jNyKI-00072X-GL; Mon, 13 Apr 2020 08:36:34 -0400 Received: (nullmailer pid 3103321 invoked by uid 1000); Mon, 13 Apr 2020 12:36:32 -0000 From: David Bremner To: David Bremner Subject: [PATCH 6/6] cli/dump: replace use of gzprintf with gzputs for config values Date: Mon, 13 Apr 2020 09:36:23 -0300 Message-Id: <20200413123623.3103260-6-david@tethera.net> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200413123623.3103260-1-david@tethera.net> References: <20200413123623.3103260-1-david@tethera.net> MIME-Version: 1.0 X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: notmuch@notmuchmail.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: notmuch-bounces@notmuchmail.org Sender: "notmuch" X-Scanner: scn0 X-Spam-Score: -0.01 Authentication-Results: aspmx2.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx2.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 50.126.95.6 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Scan-Result: default: False [-0.01 / 13.00]; RCVD_TLS_LAST(0.00)[]; GENERIC_REPUTATION(0.00)[-0.45095041502365]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; IP_REPUTATION_HAM(0.00)[asn: 27017(-0.18), country: US(-0.01), ip: 50.126.95.6(-0.45)]; R_SPF_ALLOW(-0.20)[+a]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[notmuch@notmuchmail.org]; SPF_REPUTATION_HAM(0.00)[-0.44941579851949]; HAS_LIST_UNSUB(-0.01)[]; DMARC_NA(0.00)[tethera.net]; MX_GOOD(-0.50)[cached: notmuchmail.org]; RCPT_COUNT_TWO(0.00)[2]; MID_CONTAINS_FROM(1.00)[]; MAILLIST(-0.20)[mailman]; FORGED_SENDER_MAILLIST(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:27017, ipnet:50.126.64.0/18, country:US]; FROM_NEQ_ENVFROM(0.00)[david@tethera.net,notmuch-bounces@notmuchmail.org]; RCVD_COUNT_SEVEN(0.00)[8] X-TUID: dooWhE3lgKpI These can be large, and hit buffer limitations of gzprintf. --- notmuch-dump.c | 4 +++- test/T600-named-queries.sh | 1 - 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/notmuch-dump.c b/notmuch-dump.c index 52a88283..887ef7f0 100644 --- a/notmuch-dump.c +++ b/notmuch-dump.c @@ -51,7 +51,9 @@ database_dump_config (notmuch_database_t *notmuch, gzFile output) goto DONE; } - GZPRINTF (output, " %s\n", buffer); + GZPUTS (output, " "); + GZPUTS (output, buffer); + GZPUTS (output, "\n"); } ret = EXIT_SUCCESS; diff --git a/test/T600-named-queries.sh b/test/T600-named-queries.sh index 852f7530..421a11d4 100755 --- a/test/T600-named-queries.sh +++ b/test/T600-named-queries.sh @@ -37,7 +37,6 @@ EOF test_expect_equal_file QUERIES.BEFORE OUTPUT test_begin_subtest 'dumping large queries' -test_subtest_known_broken # This value is just large enough to trigger a limitation of gzprintf # to 8191 bytes in total (by default). repeat=1329 -- 2.25.1