aboutsummaryrefslogtreecommitdiffstats
path: root/diff-lib.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-09-14 14:46:46 -0700
committerJunio C Hamano <gitster@pobox.com>2023-09-15 17:08:46 -0700
commitc33fa871a5c89091cfc89fd7b6ef504d2d48bef2 (patch)
treed8eefcf40275cd2453b3ec5a34685f28627dd095 /diff-lib.c
parentGit 2.42 (diff)
downloadgit-c33fa871a5c89091cfc89fd7b6ef504d2d48bef2.tar.gz
git-c33fa871a5c89091cfc89fd7b6ef504d2d48bef2.zip
cache: add fake_lstat()
At times, we may already know that a path represented by a cache_entry ce has no changes via some out-of-line means, like fsmonitor, and yet need the control to go through a codepath that requires us to have "struct stat" obtained by lstat() on the path, for various purposes (e.g. "ie_match_stat()" wants cached stat-info is still current wrt "struct stat", "diff" wants to know st_mode). The callers of lstat() on a tracked file, when its cache_entry knows it is up-to-date, can instead call this helper to pretend that it called lstat() by faking the "struct stat" information. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff-lib.c')
0 files changed, 0 insertions, 0 deletions