diff options
author | Junio C Hamano <gitster@pobox.com> | 2020-07-09 23:00:45 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-07-09 23:00:45 +0200 |
commit | d341042f718ad39eef06ea8715f926eb17181115 (patch) | |
tree | 5015478518c40d753c7e20c828b422c5190360ec /entry.c | |
parent | Merge branch 'ma/rebase-doc-typofix' into master (diff) | |
parent | entry: check for fstat() errors after checkout (diff) | |
download | git-d341042f718ad39eef06ea8715f926eb17181115.tar.xz git-d341042f718ad39eef06ea8715f926eb17181115.zip |
Merge branch 'mt/entry-fstat-fallback-fix' into master
"git checkout" failed to catch an error from fstat() after updating
a path in the working tree.
* mt/entry-fstat-fallback-fix:
entry: check for fstat() errors after checkout
Diffstat (limited to 'entry.c')
-rw-r--r-- | entry.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -113,8 +113,7 @@ static int fstat_output(int fd, const struct checkout *state, struct stat *st) /* use fstat() only when path == ce->name */ if (fstat_is_reliable() && state->refresh_cache && !state->base_dir_len) { - fstat(fd, st); - return 1; + return !fstat(fd, st); } return 0; } |