From 9995d28927ca15a00aafd1e92203f1120813b53a Mon Sep 17 00:00:00 2001 From: "Dirk-Jan C. Binnema" Date: Tue, 13 Oct 2020 23:54:52 +0300 Subject: [PATCH] mu: indexer: update dirstamp with statbuf st_mtime --- lib/index/mu-indexer.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/index/mu-indexer.cc b/lib/index/mu-indexer.cc index 1ebb8d99..4c9bd19f 100644 --- a/lib/index/mu-indexer.cc +++ b/lib/index/mu-indexer.cc @@ -102,7 +102,6 @@ Indexer::Private::handler (const std::string& fullpath, struct stat *statbuf, { switch (htype) { case Scanner::HandleType::EnterDir: { - // in lazy-mode, we ignore this dir if its dirstamp suggest it // is up-to-date (this is _not_ always true; hence we call it // lazy-mode) @@ -134,7 +133,7 @@ Indexer::Private::handler (const std::string& fullpath, struct stat *statbuf, } case Scanner::HandleType::LeaveDir: { - store_.set_dirstamp(fullpath, ::time({})); + store_.set_dirstamp(fullpath, statbuf->st_mtime); return true; }