From 48d33532bb58c2ff61d687011dc0283e3ff536b0 Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 28 Jun 2016 10:24:07 +0200 Subject: [PATCH 01/12] test: don't use dump and restore in a pipeline This has been wrong since bbbdf0478ea, but the race condition was not previously been (often?) triggered in the tests. With the DB_RETRY_LOCK patches, it manifests itself as a deadlock. --- test/T240-dump-restore.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/T240-dump-restore.sh b/test/T240-dump-restore.sh index e6976ff8..97e9e7f9 100755 --- a/test/T240-dump-restore.sh +++ b/test/T240-dump-restore.sh @@ -135,7 +135,8 @@ test_expect_equal_file EXPECTED OUT test_begin_subtest "format=batch-tag, # round-trip" notmuch dump --format=sup | sort > EXPECTED.$test_count -notmuch dump --format=batch-tag | notmuch restore --format=batch-tag +notmuch dump --format=batch-tag > DUMPFILE +notmuch restore --format=batch-tag < DUMPFILE notmuch dump --format=sup | sort > OUTPUT.$test_count test_expect_equal_file EXPECTED.$test_count OUTPUT.$test_count @@ -212,7 +213,8 @@ test_expect_equal_file EXPECTED OUTPUT.$test_count test_begin_subtest 'format=batch-tag, round trip with strange tags' notmuch dump --format=batch-tag > EXPECTED.$test_count -notmuch dump --format=batch-tag | notmuch restore --format=batch-tag +notmuch dump --format=batch-tag > DUMPFILE +notmuch restore --format=batch-tag < DUMPFILE notmuch dump --format=batch-tag > OUTPUT.$test_count test_expect_equal_file EXPECTED.$test_count OUTPUT.$test_count From f2886b80c1addc3d358ba910a4eebf76ba74c00b Mon Sep 17 00:00:00 2001 From: David Bremner Date: Mon, 27 Jun 2016 20:38:40 +0200 Subject: [PATCH 02/12] doc: forbid further operations on a closed database We could add many null pointer checks, but currently I don't see a use case that justifies it. --- lib/notmuch.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/notmuch.h b/lib/notmuch.h index cb46fc05..a43e167c 100644 --- a/lib/notmuch.h +++ b/lib/notmuch.h @@ -331,7 +331,9 @@ notmuch_database_status_string (const notmuch_database_t *notmuch); * functions on objects derived from this database may either behave * as if the database had not been closed (e.g., if the required data * has been cached) or may fail with a - * NOTMUCH_STATUS_XAPIAN_EXCEPTION. + * NOTMUCH_STATUS_XAPIAN_EXCEPTION. The only further operation + * permitted on the database itself is to call + * notmuch_database_destroy. * * notmuch_database_close can be called multiple times. Later calls * have no effect. From ff9284db6ebec1e4cbd7528d63da3cdf4ea9ddff Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 7 Jun 2016 07:37:57 -0300 Subject: [PATCH 03/12] lib: fix definition of LIBNOTMUCH_CHECK_VERSION Fix bug reported in id:20160606124522.g2y2eazhhrwjsa4h@flatcap.org Although the C99 standard 6.10 is a little non-obvious on this point, the docs for e.g. gcc are unambiguous. And indeed in practice with the extra space, this code fails #include #define foo (x) (x+1) int main(int argc, char **argv){ printf("%d\n",foo(1)); } --- lib/notmuch.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/notmuch.h b/lib/notmuch.h index a43e167c..24944f0b 100644 --- a/lib/notmuch.h +++ b/lib/notmuch.h @@ -93,7 +93,7 @@ NOTMUCH_BEGIN_DECLS * #endif * @endcode */ -#define LIBNOTMUCH_CHECK_VERSION (major, minor, micro) \ +#define LIBNOTMUCH_CHECK_VERSION(major, minor, micro) \ (LIBNOTMUCH_MAJOR_VERSION > (major) || \ (LIBNOTMUCH_MAJOR_VERSION == (major) && LIBNOTMUCH_MINOR_VERSION > (minor)) || \ (LIBNOTMUCH_MAJOR_VERSION == (major) && LIBNOTMUCH_MINOR_VERSION == (minor) && \ From 9e6017b8b48db2268e7fc772c6009935838cc7e4 Mon Sep 17 00:00:00 2001 From: Stefano Zacchiroli Date: Thu, 21 Apr 2016 14:10:25 -0400 Subject: [PATCH 04/12] notmuch-mutt: use env to locate perl for increased portability Note: this patch drops -w from the shebang line, but we still have "use warnings" in the script, which is superior anyhow. Thanks Andreas Tolfsen for the suggestion. --- contrib/notmuch-mutt/notmuch-mutt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/notmuch-mutt/notmuch-mutt b/contrib/notmuch-mutt/notmuch-mutt index b47b3651..97fb2d85 100755 --- a/contrib/notmuch-mutt/notmuch-mutt +++ b/contrib/notmuch-mutt/notmuch-mutt @@ -1,4 +1,4 @@ -#!/usr/bin/perl -w +#!/usr/bin/env perl # # notmuch-mutt - notmuch (of a) helper for Mutt # From 308b44290d8b2bfc0196964bb860d6a5c0781073 Mon Sep 17 00:00:00 2001 From: David Bremner Date: Thu, 30 Jun 2016 17:52:42 +0200 Subject: [PATCH 05/12] version: bump to 0.21.1~rc0 Getting ready for the point release --- bindings/python/notmuch/version.py | 2 +- version | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bindings/python/notmuch/version.py b/bindings/python/notmuch/version.py index c1d472be..df5794f6 100644 --- a/bindings/python/notmuch/version.py +++ b/bindings/python/notmuch/version.py @@ -1,3 +1,3 @@ # this file should be kept in sync with ../../../version -__VERSION__ = '0.22' +__VERSION__ = '0.22.1~rc0' SOVERSION = '4' diff --git a/version b/version index e3462940..6f56c09b 100644 --- a/version +++ b/version @@ -1 +1 @@ -0.22 +0.22.1~rc0 From 09b18ae8f459ccdb1e5706818b4bf45ceea65e23 Mon Sep 17 00:00:00 2001 From: David Bremner Date: Thu, 30 Jun 2016 21:28:31 +0200 Subject: [PATCH 06/12] debian: add changelog stanza for 0.22.1~rc0-1 No actual changes discussed, because the NEWS file is yet to be created. --- debian/changelog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/changelog b/debian/changelog index fdb14edd..1a2a494f 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +notmuch (0.22.1~rc0-1) experimental; urgency=medium + + * release candidate for bugfix release + + -- David Bremner Thu, 30 Jun 2016 21:28:13 +0200 + notmuch (0.22-1) unstable; urgency=medium * New upstream release. See /usr/share/doc/notmuch/NEWS for new From 713f7d0c0c2859e4e5d84d2564c7ec1bd506c73c Mon Sep 17 00:00:00 2001 From: David Bremner Date: Wed, 13 Jul 2016 19:48:13 -0300 Subject: [PATCH 07/12] NEWS: initial NEWS for 0.22.1 --- NEWS | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/NEWS b/NEWS index c945c245..0e8c37e0 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,34 @@ +Notmuch 0.22.1 (UNRELEASED) +=========================== + +Library +------- + +Correct the definition of `LIBNOTMUCH_CHECK_VERSION`. + +Document the (lack of) operations permitted on a closed database. + +Test Suite +---------- + +Fix race condition in dump / restore tests. + +Notmuch-Mutt +------------ + +Use `env` to locate perl. + +Emacs +----- + +Tell `message-mode` mode that outgoing messages are mail + + This makes message-mode configuration behave more predictably. + +Respect charset of MIME parts when reading them + + Fix previous assumption that everyone uses UTF-8. + Notmuch 0.22 (2016-04-26) ========================= From 51816247d2eacf0af3367c0db85d710a7788797b Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 19 Jul 2016 06:33:37 -0300 Subject: [PATCH 08/12] version: bump to 0.22 --- bindings/python/notmuch/version.py | 2 +- version | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bindings/python/notmuch/version.py b/bindings/python/notmuch/version.py index df5794f6..0dcbb4e3 100644 --- a/bindings/python/notmuch/version.py +++ b/bindings/python/notmuch/version.py @@ -1,3 +1,3 @@ # this file should be kept in sync with ../../../version -__VERSION__ = '0.22.1~rc0' +__VERSION__ = '0.22.1' SOVERSION = '4' diff --git a/version b/version index 6f56c09b..a723ece7 100644 --- a/version +++ b/version @@ -1 +1 @@ -0.22.1~rc0 +0.22.1 From 2d2d00108151873800deb5a62cdf9d93fb188b14 Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 19 Jul 2016 06:36:15 -0300 Subject: [PATCH 09/12] NEWS: set date of point release --- NEWS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 0e8c37e0..3db6aba9 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,4 @@ -Notmuch 0.22.1 (UNRELEASED) +Notmuch 0.22.1 (2016-07-19) =========================== Library From b824ecc48f1e838ab19e346b0eec17ff02432493 Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 19 Jul 2016 06:43:20 -0300 Subject: [PATCH 10/12] debian: changelog stanza for 0.22.1-1 Basically copy upstream NEWS --- debian/changelog | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/debian/changelog b/debian/changelog index 1a2a494f..916100d9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,14 @@ +notmuch (0.22.1-1) unstable; urgency=medium + + * Correct the definition of `LIBNOTMUCH_CHECK_VERSION`. + * Document the (lack of) operations permitted on a closed database + (Closes: #826843). + * Fix race condition in dump / restore tests. + * [notmuch-emacs] Tell `message-mode` mode that outgoing messages are mail + * [notmuch-emacs] Respect charset of MIME parts when reading them + + -- David Bremner Tue, 19 Jul 2016 06:42:09 -0300 + notmuch (0.22.1~rc0-1) experimental; urgency=medium * release candidate for bugfix release From 6cf6469e91938afafd22c34773168436a63ca47c Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 19 Jul 2016 08:47:47 -0300 Subject: [PATCH 11/12] debian: add explicit build-depends on gnupg apt dropped it's depends on gnupg, so we can't rely on it being present in the build env anymore --- debian/control | 1 + 1 file changed, 1 insertion(+) diff --git a/debian/control b/debian/control index a46e391b..2cd24213 100644 --- a/debian/control +++ b/debian/control @@ -24,6 +24,7 @@ Build-Depends: gdb [!s390x !ia64 !armel !ppc64el !mips !mipsel !mips64el], dtach (>= 0.8), gpgsm , + gnupg , bash-completion (>=1.9.0~) Standards-Version: 3.9.6 Homepage: http://notmuchmail.org/ From 8fe58226ef81e9600c97675e62d4a78e0f6eeefe Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 19 Jul 2016 08:51:33 -0300 Subject: [PATCH 12/12] debian: changelog stanza for 0.22.1-2 --- debian/changelog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/changelog b/debian/changelog index 916100d9..bac4fcb9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +notmuch (0.22.1-2) unstable; urgency=medium + + * Add explicit build-depends on gnupg, for the test suite. + + -- David Bremner Tue, 19 Jul 2016 08:50:13 -0300 + notmuch (0.22.1-1) unstable; urgency=medium * Correct the definition of `LIBNOTMUCH_CHECK_VERSION`.