From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 8PZAHgrY2WHSJwAAgWs5BA (envelope-from ) for ; Sat, 08 Jan 2022 19:29:30 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id WJjbGgrY2WF4eQEAauVa8A (envelope-from ) for ; Sat, 08 Jan 2022 19:29:30 +0100 Received: from mail.notmuchmail.org (yantan.tethera.net [IPv6:2a01:4f9:c011:7a79::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 2246413EF7 for ; Sat, 8 Jan 2022 19:29:30 +0100 (CET) Received: from yantan.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id AEA975F728; Sat, 8 Jan 2022 18:29:26 +0000 (UTC) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by mail.notmuchmail.org (Postfix) with ESMTP id C0FE65F718 for ; Sat, 8 Jan 2022 18:29:23 +0000 (UTC) Received: by fethera.tethera.net (Postfix, from userid 1001) id 584395FC42; Sat, 8 Jan 2022 13:29:23 -0500 (EST) Received: (nullmailer pid 3147628 invoked by uid 1000); Sat, 08 Jan 2022 18:29:22 -0000 From: David Bremner To: Austin Ray , notmuch@notmuchmail.org Subject: [PATCH 2/2] lib/database: delete stemmer on destroy Date: Sat, 8 Jan 2022 14:28:44 -0400 Message-Id: <20220108182844.3147598-2-david@tethera.net> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220108182844.3147598-1-david@tethera.net> References: <20220105224538.m36lnjn7rf3ieonc@athena> <20220108182844.3147598-1-david@tethera.net> MIME-Version: 1.0 Message-ID-Hash: OMI55XFDAXXY5OITZ2OEX56XIFGOC7N6 X-Message-ID-Hash: OMI55XFDAXXY5OITZ2OEX56XIFGOC7N6 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; digests; suspicious-header X-Mailman-Version: 3.3.3 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN X-Migadu-Country: DE ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1641666570; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-owner:list-unsubscribe:list-subscribe:list-post; bh=XCxVyAG1Z8a+rcKvryyMusxPaHIU5FOK2ZTD/SxYwiM=; b=m6IDmaM0U5Uw9wm04DvTF7QBcW8YTwMThdFDwGrKNUFccOPIoeokZVdc2E53hiYzdc1sJp c2Jh/vW0DM2VHw+Mv8NmYiU0sfxNwKstebeZeTL+z6OJJZql28bQUvZYvNr3HwCQcCTVwS WTk0//MtcLvzt0HY9EdiTtwoKygpTnwWVwrmvbOh2LmYUQgA8sb+YtY6Bsx4CIpEqwhWms XRxjLa0K46EHVKaTdZGqL+DKcMuFOWLYK2bKb5GrS7UAqG2IBmwxy6J83Lp76mP85e2Ala u3Er+xka+MiLoFxRGuB5eK/U5TbVe9mCK9yoYAEibcnSuuUFErVsQfcSvGBNng== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1641666570; a=rsa-sha256; cv=none; b=AfuLnROEMAkv+oJydwWKd4yBC8nwvK0Yh6hGNbo0Sg+/FOkiZWkPY7VGGghdH04vd+nCkr S2/P8vS/Rxt6Bh1DVkogoZBQwa93vkDViBTWklG2yYZo4GVStF8Ab5FLjS0dIBt5kXxRXm ME76uhUGhAsc/YHmlnU+6exctVezkT5Dj3XSPTxq8gli7YxK81JuzJpDPAdfC+XD/9AThM eMVCcYrHrF6Kb7SL82mMo+PmfNZ8kzjmWF6OfWebnrSPaojT5Vrzgf0miv2JFdmypEYAhk GOAEP36rhIKQ9GbiTuCwn6wCp7rdhyKc86SFYMk4K20o9bWnrK6VTX9vYKV5rg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 2a01:4f9:c011:7a79::1 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -1.79 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 2a01:4f9:c011:7a79::1 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: 2246413EF7 X-Spam-Score: -1.79 X-Migadu-Scanner: scn0.migadu.com X-TUID: 9zyISiUB7kG8 Commit 3202e0d1feba1ab955ba1c07098c00208f8f0ada left the stemmer object accessible, but did not add de-allocation code to notmuch_database_destroy. This commit corrects that oversight. --- lib/database.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/database.cc b/lib/database.cc index 6ef56d56..a012ebcf 100644 --- a/lib/database.cc +++ b/lib/database.cc @@ -753,6 +753,8 @@ notmuch_database_destroy (notmuch_database_t *notmuch) notmuch->date_range_processor = NULL; delete notmuch->last_mod_range_processor; notmuch->last_mod_range_processor = NULL; + delete notmuch->stemmer; + notmuch->stemmer = NULL; talloc_free (notmuch); -- 2.34.1