X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=notmuch-new.c;h=ba5bb5ac7b7f202ccbd7831d2105e780fb03eb36;hp=8172b498a3fbd43870367171dccea3a6542c45af;hb=c835e2a5059ebc10580f8ae2a79c4f0f81374798;hpb=d024ab4a046b0eb53bfdbb7eb9d5f25a52172271 diff --git a/notmuch-new.c b/notmuch-new.c index 8172b498..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. @@ -159,6 +159,7 @@ add_files_recursive (notmuch_database_t *notmuch, * user specify files to be ignored. */ if (strcmp (entry->d_name, ".") == 0 || strcmp (entry->d_name, "..") == 0 || + strcmp (entry->d_name, "tmp") == 0 || strcmp (entry->d_name, ".notmuch") ==0) { continue;