]> git.notmuchmail.org Git - notmuch/commit
notmuch new: Eliminate the check on the mtime of regular files before adding.
authorCarl Worth <cworth@cworth.org>
Tue, 5 Jan 2010 23:59:11 +0000 (15:59 -0800)
committerCarl Worth <cworth@cworth.org>
Wed, 6 Jan 2010 18:32:06 +0000 (10:32 -0800)
commitdde214c768a948222786b4c2b5ec404a4ffacc8c
tree5d59fdcb90c87d7755c7e940d346fbc81143fd11
parent2ce46c31fe44ea1c7fc75a7da83e1278d06c28e1
notmuch new: Eliminate the check on the mtime of regular files before adding.

This check was buggy in that moving a pre-existing file into the mail
store, (where the file existed before the last run of "notmuch new"),
does not update the mtime of the file. So the message would never be
added to the database.

The fix here is not practical in the long run, (since it causes *all*
files in the mail store to be processed in every run of "notmuch new"
(!)). But this change will let us drop a stat() call that we don't
otherwise need and will help move us toward proper database-backed
detection of new files, (which will fix the bug without the
performance impact of the current fix).
notmuch-new.c