Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 6C13B429E21 for ; Fri, 28 Oct 2011 07:56:47 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -2.3 X-Spam-Level: X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_MED=-2.3] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TksW1qlyJwTH for ; Fri, 28 Oct 2011 07:56:46 -0700 (PDT) Received: from tempo.its.unb.ca (tempo.its.unb.ca [131.202.1.21]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id B35BF431FB6 for ; Fri, 28 Oct 2011 07:56:46 -0700 (PDT) Received: from convex-new.cs.unb.ca ([131.202.13.154]) by tempo.its.unb.ca (8.13.8/8.13.8) with ESMTP id p9SEudDO014871; Fri, 28 Oct 2011 11:56:41 -0300 Received: from bremner by convex-new.cs.unb.ca with local (Exim 4.72) (envelope-from ) id 1RJnrL-0004XT-KI; Fri, 28 Oct 2011 11:56:39 -0300 From: David Bremner To: notmuch@notmuchmail.org Subject: [PATCH] lib/database.cc: use flush Xapian method instead of commit Date: Fri, 28 Oct 2011 11:56:30 -0300 Message-Id: <1319813790-17418-1-git-send-email-david@tethera.net> X-Mailer: git-send-email 1.7.5.4 Cc: David Bremner X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Oct 2011 14:56:48 -0000 From: David Bremner Apparently the method was renamed in Xapian 1.1.0 but the old method name will stay around for a while. It seems better to stick with the old name to make notmuch compile with older versions of Xapian, at least for now. --- lib/database.cc | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/lib/database.cc b/lib/database.cc index e77fd53..5440df2 100644 --- a/lib/database.cc +++ b/lib/database.cc @@ -1030,7 +1030,7 @@ notmuch_database_end_atomic (notmuch_database_t *notmuch) * However, we rely on flushing to test atomicity. */ const char *thresh = getenv ("XAPIAN_FLUSH_THRESHOLD"); if (thresh && atoi (thresh) == 1) - db->commit (); + db->flush (); } catch (const Xapian::Error &error) { fprintf (stderr, "A Xapian exception occurred committing transaction: %s.\n", error.get_msg().c_str()); -- 1.7.5.4