diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-04-03 09:18:01 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-04-03 09:18:01 -0700 |
commit | 92e0d916326de103e463f9ffcfcd99ec1f3a9dc0 (patch) | |
tree | 91c7fc235e4d52169b13602eeedbc9c42b407440 /read-cache.c | |
parent | 40a0f842daca9ebcb0e0f286b9af74c05ae4a1ae (diff) | |
parent | 072dda68eafdefe56f9305c547771367353cf89d (diff) | |
download | git-92e0d916326de103e463f9ffcfcd99ec1f3a9dc0.tar.gz git-92e0d916326de103e463f9ffcfcd99ec1f3a9dc0.tar.xz |
Sync with 1.8.1 maintenance track
* maint-1.8.1:
Start preparing for 1.8.1.6
git-tag(1): we tag HEAD by default
Fix revision walk for commits with the same dates
t2003: work around path mangling issue on Windows
pack-refs: add fully-peeled trait
pack-refs: write peeled entry for non-tags
use parse_object_or_die instead of die("bad object")
avoid segfaults on parse_object failure
entry: fix filter lookup
t2003: modernize style
name-hash.c: fix endless loop with core.ignorecase=true
Diffstat (limited to 'read-cache.c')
-rw-r--r-- | read-cache.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/read-cache.c b/read-cache.c index 670a06bc7..5a9704f4e 100644 --- a/read-cache.c +++ b/read-cache.c @@ -46,7 +46,7 @@ static void replace_index_entry(struct index_state *istate, int nr, struct cache { struct cache_entry *old = istate->cache[nr]; - remove_name_hash(old); + remove_name_hash(istate, old); set_index_entry(istate, nr, ce); istate->cache_changed = 1; } @@ -460,7 +460,7 @@ int remove_index_entry_at(struct index_state *istate, int pos) struct cache_entry *ce = istate->cache[pos]; record_resolve_undo(istate, ce); - remove_name_hash(ce); + remove_name_hash(istate, ce); istate->cache_changed = 1; istate->cache_nr--; if (pos >= istate->cache_nr) @@ -483,7 +483,7 @@ void remove_marked_cache_entries(struct index_state *istate) for (i = j = 0; i < istate->cache_nr; i++) { if (ce_array[i]->ce_flags & CE_REMOVE) - remove_name_hash(ce_array[i]); + remove_name_hash(istate, ce_array[i]); else ce_array[j++] = ce_array[i]; } @@ -1515,8 +1515,7 @@ int discard_index(struct index_state *istate) istate->cache_changed = 0; istate->timestamp.sec = 0; istate->timestamp.nsec = 0; - istate->name_hash_initialized = 0; - free_hash(&istate->name_hash); + free_name_hash(istate); cache_tree_free(&(istate->cache_tree)); istate->initialized = 0; |