Salikh Zakirov <salikh@xxxxxxxxx> writes: > I have observed incorret behaviour of git-commit after git-add -u, where > it records deletions of files not related to the files touched by commit. Does this fix the issue? Ideally remove_file_from_cache() should have the invalidate call inside just like add_file_to_cache() does, but there was a technical reason it couldn't that I do not recall offhand, so I am playing it safe here with this tentative patch to see if the cause is a cache-tree corruption. --- builtin-add.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/builtin-add.c b/builtin-add.c index 1591171..a5fae7c 100644 --- a/builtin-add.c +++ b/builtin-add.c @@ -115,6 +115,7 @@ static void update_callback(struct diff_queue_struct *q, break; case DIFF_STATUS_DELETED: remove_file_from_cache(path); + cache_tree_invalidate_path(active_cache_tree, path); if (verbose) printf("remove '%s'\n", path); break; - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html