]> git.cworth.org Git - obsolete/notmuch-old/commit
new: Merge error checks from add_files and add_files_recursive
authorAustin Clements <amdragon@MIT.EDU>
Thu, 24 May 2012 22:01:12 +0000 (18:01 -0400)
committerDavid Bremner <bremner@debian.org>
Fri, 25 May 2012 00:53:19 +0000 (21:53 -0300)
commitda170ee6573ca8a04f01ebf789250f6b4b4d3cf0
tree669de55ffad596bb33441478356e0366432eba32
parentd99270c450d8f9ef3ecfbcbeeb99b581f36c9175
new: Merge error checks from add_files and add_files_recursive

Previously, add_files_recursive could have been called on a symlink to
a non-directory.  Hence, calling it on a non-directory was not an
error, so a separate function, add_files, existed to fail loudly in
situations where the path had to be a directory.

With the new stat-ing logic, add_files_recursive is always called on
directories, so the separation of this logic is no longer necessary.
Hence, this patch moves the strict error checking previously done by
add_files into add_files_recursive.
notmuch-new.c