summaryrefslogtreecommitdiff
path: root/builtin.h
diff options
context:
space:
mode:
authorDaniel Barkalow <barkalow@iabervon.org>2008-02-07 11:39:59 -0500
committerJunio C Hamano <gitster@pobox.com>2008-02-09 23:16:51 -0800
commit33ecf7eb6143143711ccaf828134beb2dacbe5c9 (patch)
tree9d6a9b2a764dc2fe2d9b171835c690ce11a26fa2 /builtin.h
parentb05c6dff8aa8af5a03717e8d863b911cede213a0 (diff)
downloadgit-33ecf7eb6143143711ccaf828134beb2dacbe5c9.tar.gz
Discard "deleted" cache entries after using them to update the working tree
Way back in read-tree.c, we used a mode 0 cache entry to indicate that an entry had been deleted, so that the update code would remove the working tree file, and we would just skip it when writing out the index file afterward. These days, unpack_trees is a library function, and it is still leaving these entries in the active cache. Furthermore, unpack_trees doesn't correctly ignore those entries, and who knows what other code wouldn't expect them to be there, but just isn't yet called after a call to unpack_trees. To avoid having other code trip over these entries, have check_updates() remove them after it removes the working tree files. While we're at it, simplify the loop in check_updates(), and avoid passing global variables as parameters to check_updates(): there is only one call site anyway. Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
Diffstat (limited to 'builtin.h')
0 files changed, 0 insertions, 0 deletions