From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 4mQCIAdVBF8wcQAA0tVLHw (envelope-from ) for ; Tue, 07 Jul 2020 10:57:11 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id CDebGwdVBF9VawAA1q6Kng (envelope-from ) for ; Tue, 07 Jul 2020 10:57:11 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [IPv6:2607:5300:201:3100::1657]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E95A7940220 for ; Tue, 7 Jul 2020 10:57:09 +0000 (UTC) Received: from [144.217.243.247] (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 2E87B1FCC8; Tue, 7 Jul 2020 06:56:56 -0400 (EDT) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by mail.notmuchmail.org (Postfix) with ESMTP id 631881FCB5 for ; Tue, 7 Jul 2020 06:56:53 -0400 (EDT) Received: by fethera.tethera.net (Postfix, from userid 1001) id B7911613B5; Tue, 7 Jul 2020 06:56:52 -0400 (EDT) Received: (nullmailer pid 433308 invoked by uid 1000); Tue, 07 Jul 2020 10:56:48 -0000 From: David Bremner To: notmuch@notmuchmail.org Cc: David Bremner Subject: [PATCH 1/3] lib: migrate to post Xapian 1.3.4 compact support Date: Tue, 7 Jul 2020 07:56:45 -0300 Message-Id: <20200707105647.433187-2-david@tethera.net> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200707105647.433187-1-david@tethera.net> References: <20200707105647.433187-1-david@tethera.net> MIME-Version: 1.0 Message-ID-Hash: 6LNKSZWI2FCBKDZPOK7U4MTY5CSM7KI4 X-Message-ID-Hash: 6LNKSZWI2FCBKDZPOK7U4MTY5CSM7KI4 X-MailFrom: bremner@tethera.net X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.1 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 2607:5300:201:3100::1657 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Spam-Score: 1.53 X-TUID: d3gOw3AA1rO9 The old API was deprecated in Xapian 1.3.4 and (will be) removed in 1.5.0 --- lib/database.cc | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lib/database.cc b/lib/database.cc index 78b5fec9..43bfac4e 100644 --- a/lib/database.cc +++ b/lib/database.cc @@ -1281,11 +1281,7 @@ notmuch_database_compact (const char *path, try { NotmuchCompactor compactor (status_cb, closure); - - compactor.set_renumber (false); - compactor.add_source (xapian_path); - compactor.set_destdir (compact_xapian_path); - compactor.compact (); + notmuch->xapian_db->compact (compact_xapian_path, Xapian::DBCOMPACT_NO_RENUMBER, 0, compactor); } catch (const Xapian::Error &error) { _notmuch_database_log (notmuch, "Error while compacting: %s\n", error.get_msg ().c_str ()); ret = NOTMUCH_STATUS_XAPIAN_EXCEPTION; -- 2.27.0