aboutsummaryrefslogtreecommitdiffhomepage
path: root/notmuch-new.c
diff options
context:
space:
mode:
authorGravatar Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>2009-11-25 10:28:24 +0530
committerGravatar Carl Worth <cworth@cworth.org>2009-11-27 17:29:10 -0800
commit5c7c6c0baefaf63d2b79c014b85c391a66261feb (patch)
tree6981fa11a897cb17dc46a18914e332d22019b23e /notmuch-new.c
parentc984fc43cc841b1453a10f92c227466a2c676364 (diff)
notmuch-new: Fix notmuch new to look at files within symbolic links
We look at the modified time of the database and the directory to decide whether we need to look at only the subdirectories. ie, if directory modified time is < database modified time then we have already looking at all the files withing the directory. So we just need to iterate through the subdirectories But with symlinks we need to make sure we follow them even if the directory modified time is less than database modified time Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Diffstat (limited to 'notmuch-new.c')
-rw-r--r--notmuch-new.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/notmuch-new.c b/notmuch-new.c
index e32b92a5..ba5bb5ac 100644
--- a/notmuch-new.c
+++ b/notmuch-new.c
@@ -149,7 +149,7 @@ add_files_recursive (notmuch_database_t *notmuch,
/* If this directory hasn't been modified since the last
* add_files, then we only need to look further for
* sub-directories. */
- if (path_mtime <= path_dbtime && entry->d_type != DT_DIR)
+ if (path_mtime <= path_dbtime && entry->d_type == DT_REG)
continue;
/* Ignore special directories to avoid infinite recursion.