summaryrefslogtreecommitdiff
path: root/builtin/checkout-index.c
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2014-06-13 12:19:34 (GMT)
committerJunio C Hamano <gitster@pobox.com>2014-06-13 18:49:39 (GMT)
commitd4a2024aef90fa5dd2b0e5027f9340719ff20748 (patch)
tree6d69b97c8e8df1d5dc98c3ba138d3d58306f1065 /builtin/checkout-index.c
parente6c286e8b2d0748cfaa670f6738db0c232427cd3 (diff)
downloadgit-d4a2024aef90fa5dd2b0e5027f9340719ff20748.zip
git-d4a2024aef90fa5dd2b0e5027f9340719ff20748.tar.gz
git-d4a2024aef90fa5dd2b0e5027f9340719ff20748.tar.bz2
entry.c: update cache_changed if refresh_cache is set in checkout_entry()
Other fill_stat_cache_info() is on new entries, which should set CE_ENTRY_ADDED in cache_changed, so we're safe. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/checkout-index.c')
-rw-r--r--builtin/checkout-index.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/builtin/checkout-index.c b/builtin/checkout-index.c
index 9e49bf2..05edd9e 100644
--- a/builtin/checkout-index.c
+++ b/builtin/checkout-index.c
@@ -135,6 +135,7 @@ static int option_parse_u(const struct option *opt,
int *newfd = opt->value;
state.refresh_cache = 1;
+ state.istate = &the_index;
if (*newfd < 0)
*newfd = hold_locked_index(&lock_file, 1);
return 0;