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 7448940D155 for ; Fri, 29 Oct 2010 13:16:04 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -2.89 X-Spam-Level: X-Spam-Status: No, score=-2.89 tagged_above=-999 required=5 tests=[ALL_TRUSTED=-1, BAYES_00=-1.9, T_MIME_NO_TEXT=0.01] autolearn=ham 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 7+L0jGnWIm1Y; Fri, 29 Oct 2010 13:15:54 -0700 (PDT) Received: from yoom.home.cworth.org (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 09F8540D149; Fri, 29 Oct 2010 13:15:54 -0700 (PDT) Received: by yoom.home.cworth.org (Postfix, from userid 1000) id 963B02540F4; Fri, 29 Oct 2010 13:15:53 -0700 (PDT) From: Carl Worth To: Mike Kelly , notmuch@notmuchmail.org Subject: Re: [PATCH] notmuch-setup.c: Initialize getline(3) response_size to 0 In-Reply-To: <1287080299-13828-1-git-send-email-pioto@pioto.org> References: <20101013094340.41580a2f@pioto.org> <1287080299-13828-1-git-send-email-pioto@pioto.org> User-Agent: Notmuch/0.3.1-137-gce6390c (http://notmuchmail.org) Emacs/23.2.1 (i486-pc-linux-gnu) Date: Fri, 29 Oct 2010 13:15:42 -0700 Message-ID: <87y69g69ht.fsf@yoom.home.cworth.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" 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, 29 Oct 2010 20:16:04 -0000 --=-=-= Content-Transfer-Encoding: quoted-printable On Thu, 14 Oct 2010 14:18:19 -0400, Mike Kelly wrote: > This appears to be necessary on FreeBSD. If this isn't done, we get a > nasty segfault. Thanks. I've pushed this out. I didn't have that initialized originally, because the documentation I have for getline on my Linux machine says explicitly: If *lineptr is NULL, then getline() will allocate a buffer for storing the line, which should be freed by the user program. (In this case, the value in *n is ignored.) But, oh well, it's easy enough to fix. Thanks again for the patch. =2DCarl =2D-=20 carl.d.worth@intel.com --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iD8DBQFMyytu6JDdNq8qSWgRAgoJAJ9L0zgJZ51Rr8W8qfNr/Ym0jU+kYQCdHqEJ ftJkKaADS0hVzu70xczA5YU= =O55N -----END PGP SIGNATURE----- --=-=-=--