Re: [PATCH 03/10] Fix compilation of smtp-dummy on FreeBSD
authorJani Nikula <jani@nikula.org>
Sat, 26 May 2012 09:52:02 +0000 (12:52 +0300)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:47:25 +0000 (09:47 -0800)
76/4c520853310b237bff460cb0f4b9f710fc0631 [new file with mode: 0644]

diff --git a/76/4c520853310b237bff460cb0f4b9f710fc0631 b/76/4c520853310b237bff460cb0f4b9f710fc0631
new file mode 100644 (file)
index 0000000..a3f9187
--- /dev/null
@@ -0,0 +1,172 @@
+Return-Path: <jani@nikula.org>\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 C51B2431FBC\r
+       for <notmuch@notmuchmail.org>; Sat, 26 May 2012 02:52:04 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.699\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.699 tagged_above=-999 required=5\r
+       tests=[HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7] 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 lVC-y45bKfYL for <notmuch@notmuchmail.org>;\r
+       Sat, 26 May 2012 02:52:04 -0700 (PDT)\r
+Received: from mail-ob0-f181.google.com (mail-ob0-f181.google.com\r
+       [209.85.214.181]) (using TLSv1 with cipher RC4-MD5 (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id 0B96A431FB6\r
+       for <notmuch@notmuchmail.org>; Sat, 26 May 2012 02:52:04 -0700 (PDT)\r
+Received: by obbuo19 with SMTP id uo19so2852496obb.26\r
+       for <notmuch@notmuchmail.org>; Sat, 26 May 2012 02:52:02 -0700 (PDT)\r
+X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
+       d=google.com; s=20120113;\r
+       h=mime-version:in-reply-to:references:date:message-id:subject:from:to\r
+       :cc:content-type:x-gm-message-state;\r
+       bh=f9LmIhh23ZScy+KQx3j3k1A86dvLQoYkyOxSsXM0eMI=;\r
+       b=N2THzcMsZ3V0MHVFGJ9/5aKdQ4712mVjqbuyBRBx2oc0Uk39NwPWiQEfoE7KZAdXsg\r
+       r9VTqqfrWG17YgkSn+luazUyG8KNrL4RJdzDpAhNhkCo1avShh4cQMwwv540IZdnQn/d\r
+       qFVKpfJ4NRQ0F2iA9Hh+qSxjsfUMX2Un4OAEcxeJJSmz5asG6iniTUhj+XUfLNzy4FCO\r
+       QNZOWzeFvFhII1eX8ThMx2/AXXhqhY3OOuTR2EqBKfcPU1OWJ8a60TssEZeXpLL0OZka\r
+       9OYwMJb2oUle/lg8W5XNo1Lxg1wjxO/+7KjO0dz8/Z8kaBVARROnv9CB6WPhsTXUeZVe\r
+       oN8Q==\r
+MIME-Version: 1.0\r
+Received: by 10.182.154.67 with SMTP id vm3mr1788127obb.57.1338025922379; Sat,\r
+       26 May 2012 02:52:02 -0700 (PDT)\r
+Received: by 10.76.173.136 with HTTP; Sat, 26 May 2012 02:52:02 -0700 (PDT)\r
+Received: by 10.76.173.136 with HTTP; Sat, 26 May 2012 02:52:02 -0700 (PDT)\r
+In-Reply-To: <1337953411-21000-4-git-send-email-pioto@pioto.org>\r
+References: <1337953411-21000-1-git-send-email-pioto@pioto.org>\r
+       <1337953411-21000-4-git-send-email-pioto@pioto.org>\r
+Date: Sat, 26 May 2012 12:52:02 +0300\r
+Message-ID:\r
+ <CAB+hUn_M7m0KPnmGwSFao9wxnzmrct+U0ZO6tGy4nRoA8eht_Q@mail.gmail.com>\r
+Subject: Re: [PATCH 03/10] Fix compilation of smtp-dummy on FreeBSD\r
+From: Jani Nikula <jani@nikula.org>\r
+To: Mike Kelly <pioto@pioto.org>\r
+Content-Type: multipart/alternative; boundary=f46d0447a06bcdc00304c0ed6f6c\r
+X-Gm-Message-State:\r
+ ALoCoQkVsVTqpZ/IK4EWhLe3ojFuxEGEQwJssNrGYAuSN2u2eLQ5lDG2k2aUkK13lkElDgxoTCnP\r
+Cc: notmuch@notmuchmail.org\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: Sat, 26 May 2012 09:52:05 -0000\r
+\r
+--f46d0447a06bcdc00304c0ed6f6c\r
+Content-Type: text/plain; charset=UTF-8\r
+\r
+On May 25, 2012 4:44 PM, "Mike Kelly" <pioto@pioto.org> wrote:\r
+>\r
+> ---\r
+>  test/smtp-dummy.c |    5 ++++-\r
+>  1 file changed, 4 insertions(+), 1 deletion(-)\r
+>\r
+> diff --git a/test/smtp-dummy.c b/test/smtp-dummy.c\r
+> index 3801a5e..aa82fa1 100644\r
+> --- a/test/smtp-dummy.c\r
+> +++ b/test/smtp-dummy.c\r
+> @@ -33,11 +33,14 @@\r
+>  * have been warned.\r
+>  */\r
+>\r
+> +#define _GNU_SOURCE /* for getline */\r
+\r
+First of all, thanks for sharing your work.\r
+\r
+Independent of this patch, I've been thinking about defining _GNU_SOURCE in\r
+the makefile. I don't think it's very elegant to #define it everywhere. It\r
+would also pave the way towards building with -pedantic (and possibly\r
+-std=c99) in a portable way. For example, the compat test code #defines\r
+_GNU_SOURCE while the actual code does not, which I think is an error.\r
+\r
+I'll look into this after the weekend (unless you beat me to it).\r
+\r
+BR,\r
+Jani.\r
+\r
+>  #include <stdio.h>\r
+>  #include <stdlib.h>\r
+>  #include <string.h>\r
+>  #include <errno.h>\r
+> -#include <netinet/ip.h>\r
+> +#include <sys/types.h>\r
+> +#include <sys/socket.h>\r
+> +#include <netinet/in.h>\r
+>  #include <netdb.h>\r
+>  #include <unistd.h>\r
+>\r
+> --\r
+> 1.7.10.2\r
+>\r
+> _______________________________________________\r
+> notmuch mailing list\r
+> notmuch@notmuchmail.org\r
+> http://notmuchmail.org/mailman/listinfo/notmuch\r
+\r
+--f46d0447a06bcdc00304c0ed6f6c\r
+Content-Type: text/html; charset=UTF-8\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+<p><br>\r
+On May 25, 2012 4:44 PM, &quot;Mike Kelly&quot; &lt;<a href=3D"mailto:pioto=\r
+@pioto.org">pioto@pioto.org</a>&gt; wrote:<br>\r
+&gt;<br>\r
+&gt; ---<br>\r
+&gt; =C2=A0test/smtp-dummy.c | =C2=A0 =C2=A05 ++++-<br>\r
+&gt; =C2=A01 file changed, 4 insertions(+), 1 deletion(-)<br>\r
+&gt;<br>\r
+&gt; diff --git a/test/smtp-dummy.c b/test/smtp-dummy.c<br>\r
+&gt; index 3801a5e..aa82fa1 100644<br>\r
+&gt; --- a/test/smtp-dummy.c<br>\r
+&gt; +++ b/test/smtp-dummy.c<br>\r
+&gt; @@ -33,11 +33,14 @@<br>\r
+&gt; =C2=A0* have been warned.<br>\r
+&gt; =C2=A0*/<br>\r
+&gt;<br>\r
+&gt; +#define _GNU_SOURCE /* for getline */</p>\r
+<p>First of all, thanks for sharing your work.</p>\r
+<p>Independent of this patch, I&#39;ve been thinking about defining _GNU_SO=\r
+URCE in the makefile. I don&#39;t think it&#39;s very elegant to #define it=\r
+ everywhere. It would also pave the way towards building with -pedantic (an=\r
+d possibly -std=3Dc99) in a portable way. For example, the compat test code=\r
+ #defines _GNU_SOURCE while the actual code does not, which I think is an e=\r
+rror.</p>\r
+\r
+<p>I&#39;ll look into this after the weekend (unless you beat me to it).</p=\r
+>\r
+<p>BR,<br>\r
+Jani.<br></p>\r
+<p>&gt; =C2=A0#include &lt;stdio.h&gt;<br>\r
+&gt; =C2=A0#include &lt;stdlib.h&gt;<br>\r
+&gt; =C2=A0#include &lt;string.h&gt;<br>\r
+&gt; =C2=A0#include &lt;errno.h&gt;<br>\r
+&gt; -#include &lt;netinet/ip.h&gt;<br>\r
+&gt; +#include &lt;sys/types.h&gt;<br>\r
+&gt; +#include &lt;sys/socket.h&gt;<br>\r
+&gt; +#include &lt;netinet/in.h&gt;<br>\r
+&gt; =C2=A0#include &lt;netdb.h&gt;<br>\r
+&gt; =C2=A0#include &lt;unistd.h&gt;<br>\r
+&gt;<br>\r
+&gt; --<br>\r
+&gt; 1.7.10.2<br>\r
+&gt;<br>\r
+&gt; _______________________________________________<br>\r
+&gt; notmuch mailing list<br>\r
+&gt; <a href=3D"mailto:notmuch@notmuchmail.org">notmuch@notmuchmail.org</a>=\r
+<br>\r
+&gt; <a href=3D"http://notmuchmail.org/mailman/listinfo/notmuch">http://not=\r
+muchmail.org/mailman/listinfo/notmuch</a></p>\r
+\r
+--f46d0447a06bcdc00304c0ed6f6c--\r