[PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-21 Thread Carl Worth
On Tue, 21 Jun 2011 12:01:17 -0400, Austin Clements wrote: > Alternatively, because of folder search, it might be better to keep a > stack of inode numbers to eliminate loops while retaining notmuch's > current approach of repeatedly indexing mail that's symlinked in > multiple folders. Yes,

[PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-21 Thread Austin Clements
On Tue, Jun 21, 2011 at 8:42 AM, Daniel Kahn Gillmor wrote: > 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

[PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-21 Thread Daniel Kahn Gillmor
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 ? ../b ./b/foo ? ../a or ... My

Re: [PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-21 Thread Austin Clements
On Tue, Jun 21, 2011 at 8:42 AM, Daniel Kahn Gillmor d...@fifthhorseman.net wrote: 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

Re: [PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-21 Thread Carl Worth
On Tue, 21 Jun 2011 12:01:17 -0400, Austin Clements amdra...@mit.edu wrote: Alternatively, because of folder search, it might be better to keep a stack of inode numbers to eliminate loops while retaining notmuch's current approach of repeatedly indexing mail that's symlinked in multiple

[PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-20 Thread Taylor Carpenter
If a symlink points to . then there will be an infinite recursion. The included patch fixes that. --- notmuch-new.c.orig 2011-06-10 00:03:09.0 -0500 +++ notmuch-new.c 2011-06-10 02:10:37.0 -0500 @@ -233,6 +233,8 @@ struct stat st; notmuch_bool_t is_maildir,

Re: [PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-20 Thread Taylor Carpenter
On 06/10/11 at 02:32P, Taylor Carpenter wrote: If a symlink points to . then there will be an infinite recursion. The included patch fixes that. I did not realize this was needed in the count function as well. New patch included that does both. --- notmuch-new.c.orig 2011-06-10

[PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-10 Thread Taylor Carpenter
On 06/10/11 at 02:32P, Taylor Carpenter wrote: > If a symlink points to . then there will be an infinite recursion. The > included patch fixes that. I did not realize this was needed in the count function as well. New patch included that does both. --- notmuch-new.c.orig 2011-06-10

[PATCH] notmuch-new.c infinite recursion symlink bug

2011-06-10 Thread Taylor Carpenter
If a symlink points to . then there will be an infinite recursion. The included patch fixes that. --- notmuch-new.c.orig 2011-06-10 00:03:09.0 -0500 +++ notmuch-new.c 2011-06-10 02:10:37.0 -0500 @@ -233,6 +233,8 @@ struct stat st; notmuch_bool_t is_maildir,