From: Steinar H. Gunderson Date: Sun, 30 Jan 2022 19:10:34 +0000 (+0100) Subject: When stat() in updatedb fails, report the path instead of just the parent directory. X-Git-Tag: 1.1.15~2 X-Git-Url: https://git.sesse.net/?p=plocate;a=commitdiff_plain;h=5aea0223dcff337761ee1cd56e62a8064b133ec2 When stat() in updatedb fails, report the path instead of just the parent directory. Reported by Kevin Locke. --- diff --git a/updatedb.cpp b/updatedb.cpp index 8d524c6..4ead43f 100644 --- a/updatedb.cpp +++ b/updatedb.cpp @@ -713,7 +713,7 @@ int scan(const string &path, int fd, dev_t parent_dev, dir_time modified, dir_ti struct stat buf; if (fstat(e.fd, &buf) != 0) { - perror(path.c_str()); + perror((path_plus_slash + e.name).c_str()); exit(1); }