Re: Concerns regarding some library functions
authorSebastian Spaeth <sebastian@sspaeth.de>
Wed, 28 Sep 2011 15:42:01 +0000 (17:42 +0200)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:39:30 +0000 (09:39 -0800)
db/8e74262c63764d98507b4a8b6c517faaf3a5a2 [new file with mode: 0644]

diff --git a/db/8e74262c63764d98507b4a8b6c517faaf3a5a2 b/db/8e74262c63764d98507b4a8b6c517faaf3a5a2
new file mode 100644 (file)
index 0000000..be97ab7
--- /dev/null
@@ -0,0 +1,106 @@
+Return-Path: <sebastian@sspaeth.de>\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 A34DC431FD0\r
+       for <notmuch@notmuchmail.org>; Wed, 28 Sep 2011 08:42:06 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.09\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.09 tagged_above=-999 required=5\r
+       tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+       RCVD_IN_DNSWL_NONE=-0.0001, T_MIME_NO_TEXT=0.01] 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 7z1NKsRW8n7J for <notmuch@notmuchmail.org>;\r
+       Wed, 28 Sep 2011 08:42:06 -0700 (PDT)\r
+Received: from homiemail-a76.g.dreamhost.com (caiajhbdccac.dreamhost.com\r
+       [208.97.132.202])\r
+       by olra.theworths.org (Postfix) with ESMTP id 37E16431FB6\r
+       for <notmuch@notmuchmail.org>; Wed, 28 Sep 2011 08:42:06 -0700 (PDT)\r
+Received: from homiemail-a76.g.dreamhost.com (localhost [127.0.0.1])\r
+       by homiemail-a76.g.dreamhost.com (Postfix) with ESMTP id 866F9458083;\r
+       Wed, 28 Sep 2011 08:42:05 -0700 (PDT)\r
+DomainKey-Signature: a=rsa-sha1; c=nofws; d=sspaeth.de; h=from:to:subject\r
+       :in-reply-to:references:date:message-id:mime-version:\r
+       content-type; q=dns; s=sspaeth.de; b=kS93x1u2UoMUDWDA63rTx4YjcQ2\r
+       xQXuDUevADTlGwjgni5T35YnGqGSmaAhiN1TgS/YwR5T4V84SXVgfn8BaK9q7e/i\r
+       qVQbcm0GJ0DovBPnxfwl3Z5zYVf4BqQXQF/ieVAYO2r9txvr6/Sne7VCYkLwaDIU\r
+       EobNZGA7xKlNrDkU=\r
+DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sspaeth.de; h=from:to\r
+       :subject:in-reply-to:references:date:message-id:mime-version:\r
+       content-type; s=sspaeth.de; bh=fTLc8jTBu5McJGdLkNyU5uaxZvI=; b=A\r
+       RCMVvTPgyZG9T66wCzMeOCJ3KK62rEQnfHFTuDAK4RyqTFDNuzmEYxhXhk/d75kz\r
+       +3I8HUjcJvlwT0pBpT7Q8Y3g7yScIFGEfixhFL15APuumZTadYkDVVPTw2FKZjwJ\r
+       cnDao2V7IZFU1Jx4qAOGHWtL1Yh5ZY86DliqoplyEg=\r
+Received: from spaetzbook.sspaeth.de (mtec-hg-docking-2-dhcp-194.ethz.ch\r
+       [82.130.121.194])\r
+       (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       (Authenticated sender: fax@sspaeth.de)\r
+       by homiemail-a76.g.dreamhost.com (Postfix) with ESMTPSA id 7720A458081; \r
+       Wed, 28 Sep 2011 08:42:03 -0700 (PDT)\r
+Received: by spaetzbook.sspaeth.de (sSMTP sendmail emulation);\r
+       Wed, 28 Sep 2011 17:42:01 +0200\r
+From: Sebastian Spaeth <sebastian@sspaeth.de>\r
+To: Ali Polatel <polatel@gmail.com>, notmuch@notmuchmail.org\r
+Subject: Re: Concerns regarding some library functions\r
+In-Reply-To: <871uv2unfd.fsf@gmail.com>\r
+References: <871uv2unfd.fsf@gmail.com>\r
+User-Agent: Notmuch/0.7-19-gee4579a (http://notmuchmail.org) Emacs/23.2.1\r
+       (x86_64-pc-linux-gnu)\r
+Date: Wed, 28 Sep 2011 17:42:01 +0200\r
+Message-ID: <87ipocoera.fsf@SSpaeth.de>\r
+MIME-Version: 1.0\r
+Content-Type: multipart/signed; boundary="=-=-=";\r
+       micalg=pgp-sha1; protocol="application/pgp-signature"\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: Wed, 28 Sep 2011 15:42:06 -0000\r
+\r
+--=-=-=\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+On Tue, 27 Sep 2011 16:25:58 +0300, Ali Polatel wrote:\r
+> The two functions I've mentioned above are\r
+> notmuch_database_find_message() and\r
+> notmuch_database_find_message_by_filename().\r
+>=20\r
+> The problem with their design is NULL return may both mean an error\r
+> condition and "message not found". However, we already have a similar\r
+> function which does not have such a flaw, namely notmuch_database_add_mes=\r
+sage().\r
+\r
+Yes, this is because NULL used to mean message not found and NULL means\r
+error was tacked on later (because cworth did not expect that xapian\r
+would actually throw errors that often (such as database modified and\r
+whatnot). So the meaning of NULL is, ahhem, suboptimal...\r
+\r
+ERROR or really not there? There are mails from me, commenting on\r
+that. I would welcome receiving back a notmuch_status_t value and have a\r
+separate notmuch_message_t parameter which receives the actual message.\r
+\r
+Sebastian\r
+\r
+--=-=-=\r
+Content-Type: application/pgp-signature\r
+\r
+-----BEGIN PGP SIGNATURE-----\r
+Version: GnuPG v1.4.11 (GNU/Linux)\r
+\r
+iEYEARECAAYFAk6DQEkACgkQVYX1jMgnoGL3IQCfRiU9//SCkK1nfbE0/cZRotKZ\r
+iJYAnA5GSWb3tmvY/ulL7OcF7lhePC0B\r
+=GzPU\r
+-----END PGP SIGNATURE-----\r
+--=-=-=--\r