diff options
author | Thomas Rast <trast@student.ethz.ch> | 2011-12-06 18:43:37 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-12-06 14:57:36 -0800 |
commit | 996277c520641d650dc15ad751cc4ad33318e298 (patch) | |
tree | 53ba60089bcd1c336438f7ac7d5f2d124029fece /cache-tree.h | |
parent | 4eb0346fb8f8a59a1fb7a6bd01154655a7020087 (diff) | |
download | git-996277c520641d650dc15ad751cc4ad33318e298.tar.gz |
Refactor cache_tree_update idiom from commit
We'll need to safely create or update the cache-tree data of the_index
from other places. While at it, give it an argument that lets us
silence the messages produced by unmerged entries (which prevent it
from working).
Signed-off-by: Thomas Rast <trast@student.ethz.ch>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'cache-tree.h')
-rw-r--r-- | cache-tree.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cache-tree.h b/cache-tree.h index 3df641f593..0ec0b2a159 100644 --- a/cache-tree.h +++ b/cache-tree.h @@ -29,7 +29,9 @@ void cache_tree_write(struct strbuf *, struct cache_tree *root); struct cache_tree *cache_tree_read(const char *buffer, unsigned long size); int cache_tree_fully_valid(struct cache_tree *); -int cache_tree_update(struct cache_tree *, struct cache_entry **, int, int, int); +int cache_tree_update(struct cache_tree *, struct cache_entry **, int, int, int, int); + +int update_main_cache_tree(int); /* bitmasks to write_cache_as_tree flags */ #define WRITE_TREE_MISSING_OK 1 |