--- /dev/null
+Return-Path: <davrieb@liegesta.at>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by olra.theworths.org (Postfix) with ESMTP id 6F988431FB6\r
+ for <notmuch@notmuchmail.org>; Sun, 6 Nov 2011 04:23:11 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
+ autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+ by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id rYO3nnQqr4ur for <notmuch@notmuchmail.org>;\r
+ Sun, 6 Nov 2011 04:23:10 -0800 (PST)\r
+Received: from plum.liegesta.at (plum.liegesta.at [83.169.17.237])\r
+ by olra.theworths.org (Postfix) with ESMTP id DF0D8429E27\r
+ for <notmuch@notmuchmail.org>; Sun, 6 Nov 2011 04:23:09 -0800 (PST)\r
+Received: from ambiguous-mid.liegesta.at (mk046207255168.a1.net\r
+ [46.207.255.168]) (Authenticated sender: davrieb)\r
+ by plum.liegesta.at (Postfix) with ESMTPA id 197A627B8230;\r
+ Sun, 6 Nov 2011 13:23:08 +0100 (CET)\r
+Received: by ambiguous-mid.liegesta.at (Postfix, from userid 1000)\r
+ id DEEAC1FF24; Sun, 6 Nov 2011 12:23:06 +0100 (CET)\r
+From: David Riebenbauer <davrieb@liegesta.at>\r
+To: Notmuch Mailing List <notmuch@notmuchmail.org>\r
+Subject: [PATCH 0/3] notmuch-deliver: wait for database to become unlocked and\r
+ test\r
+Date: Sun, 6 Nov 2011 12:23:01 +0100\r
+Message-Id: <1320578584-6642-1-git-send-email-davrieb@liegesta.at>\r
+X-Mailer: git-send-email 1.7.7.1\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Sun, 06 Nov 2011 12:23:11 -0000\r
+\r
+Hi,\r
+\r
+I noticed that mail would bounce in my setup, if the xapian database\r
+was locked while notmuch-deliver tried to run.\r
+\r
+My solution was to make it wait for some time adn retry. A test\r
+program for is alos included.\r
+\r
+Regards,\r
+David\r
+\r
+David Riebenbauer (3):\r
+ notmuch-deliver: wait for the database to become unlocked\r
+ notmuch-deliver: test wait for database to become available\r
+ notmuch-deliver: Convert test program to glib main loop.\r
+\r
+ contrib/notmuch-deliver/.gitignore | 2 +\r
+ contrib/notmuch-deliver/Makefile.am | 2 +-\r
+ contrib/notmuch-deliver/configure.ac | 1 +\r
+ contrib/notmuch-deliver/src/main.c | 25 +++-\r
+ contrib/notmuch-deliver/test/Makefile.am | 26 +++\r
+ contrib/notmuch-deliver/test/nm-test.sh | 9 +\r
+ contrib/notmuch-deliver/test/nm-testconfig | 12 ++\r
+ contrib/notmuch-deliver/test/notmuch-lock.c | 226 +++++++++++++++++++++++++++\r
+ contrib/notmuch-deliver/test/testmail | 7 +\r
+ 9 files changed, 306 insertions(+), 4 deletions(-)\r
+ create mode 100644 contrib/notmuch-deliver/test/Makefile.am\r
+ create mode 100755 contrib/notmuch-deliver/test/nm-test.sh\r
+ create mode 100644 contrib/notmuch-deliver/test/nm-testconfig\r
+ create mode 100644 contrib/notmuch-deliver/test/notmuch-lock.c\r
+ create mode 100644 contrib/notmuch-deliver/test/testmail\r
+\r
+-- \r
+1.7.7.1\r
+\r