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 20B92431FD0 for ; Tue, 21 Jun 2011 05:42:47 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] autolearn=disabled 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 vUIaVqOE4M8S for ; Tue, 21 Jun 2011 05:42:46 -0700 (PDT) Received: from che.mayfirst.org (che.mayfirst.org [209.234.253.108]) by olra.theworths.org (Postfix) with ESMTP id BAA5E431FB6 for ; Tue, 21 Jun 2011 05:42:46 -0700 (PDT) Received: from [192.168.13.75] (lair.fifthhorseman.net [216.254.116.241]) by che.mayfirst.org (Postfix) with ESMTPSA id A8EE9F970 for ; Tue, 21 Jun 2011 08:42:44 -0400 (EDT) Message-ID: <4E0091AE.5070609@fifthhorseman.net> Date: Tue, 21 Jun 2011 08:42:22 -0400 From: Daniel Kahn Gillmor User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.17) Gecko/20110516 Icedove/3.1.10 MIME-Version: 1.0 To: notmuch@notmuchmail.org Subject: Re: [PATCH] notmuch-new.c infinite recursion symlink bug References: <20110610073208.GA74787@codecafe.com> In-Reply-To: <20110610073208.GA74787@codecafe.com> X-Enigmail-Version: 1.1.2 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="------------enig025FA00585AEAC79EB1990CB" X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: notmuch List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Jun 2011 12:42:47 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig025FA00585AEAC79EB1990CB Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 06/10/2011 03:32 AM, Taylor Carpenter wrote: > If a symlink points to . then there will be an infinite recursion. The= included patch fixes that. what about a sub-directory that contains a symlink to ".." ? or a directory that contains both: ./a/foo =E2=86=92 ../b ./b/foo =E2=86=92 ../a or ... My point is: there are lots of ways to get infinite recursions via symlinks; hard-coding a check for one specific way seems like a sub-optimal approach, because it leaves the other paths still present, and introduces an unexpected/surprising asymmetry. I'm not sure what the specific right way is to solve the problem you identified, though. --dkg --------------enig025FA00585AEAC79EB1990CB Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQJ8BAEBCgBmBQJOAJGuXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQwRUU1QkU5NzkyODJEODBCOUY3NTQwRjFD Q0QyRUQ5NEQyMTczOUU5AAoJEMzS7ZTSFznpiG0P/jWnLtl/jNUVJVCm7RMI6OOG tzyPL/VvvnHVgdjECDwx5gtsO+7D9udgE1L8lPwwtYZ4C1wn2sSLT5NI3FdXxq4K JVCKWNwXzQndTupqSJHtfDBqZTmGBK22u9yfRXNKfRpm1L9tjAq8htWmWZ5LSmZk 4oJoArPwMaGuwrdHr/4LHwPa3Ewqfq5wNxrnBA7KchTSiobAS01ZtZAWnxBSsCXf GbD457GRaHZSDqyY4InlLMHhnxd5GS6erHppHlzD7ADYC287c8HYaS7MddOahzFQ NEIXLMriteIrilurONCwgMEYKWW18dzFijud/IVFMsuWpnvHdIjV/En2LkOF6jDU PDiiA3UisdsP7vMCQ9hnCBaHuo0I6RPSXyCSb9LgoHXWLrCb2OXoRF3JkvjqS8u3 qqcpUERIlspWl6hfgGxn4oPxrT9xy3kaXJd3IlaRFP7Qt13/jasc9MR5/N5SjBlD m2wqpVf90m+Rcw6qx5/yuabNfqkWJjCqydofkYzjB7n8l53OgKKY73gHbiOS6x4l 0zh4qj3+oLREdCNSACF1ZcXXr2IqXQl0HZQ8tgk/1B6xFD3y5pD/DYJKy/Uebefm 7N9EMwa2zlAG9YElitT7wy/RxosWidMXwMALAOUTvuRyVXrt9Sz5CIOpu76MfAS8 K9T3G2DEcN6sYMDNuq15 =pnpR -----END PGP SIGNATURE----- --------------enig025FA00585AEAC79EB1990CB--