]> git.ipfire.org Git - thirdparty/git.git/blobdiff - merge-recursive.c
pack-revindex: hide the definition of 'revindex_entry'
[thirdparty/git.git] / merge-recursive.c
index d0214335a79ddef7202e0552b80111a05c36f14c..b052974f191cd82741475a019076c90e45d6d4de 100644 (file)
@@ -2651,7 +2651,7 @@ static struct string_list *get_renames(struct merge_options *opt,
                free(e->target_file);
                string_list_clear(&e->source_files, 0);
        }
-       hashmap_free_entries(&collisions, struct collision_entry, ent);
+       hashmap_clear_and_free(&collisions, struct collision_entry, ent);
        return renames;
 }
 
@@ -2870,7 +2870,7 @@ static void initial_cleanup_rename(struct diff_queue_struct *pairs,
                strbuf_release(&e->new_dir);
                /* possible_new_dirs already cleared in get_directory_renames */
        }
-       hashmap_free_entries(dir_renames, struct dir_rename_entry, ent);
+       hashmap_clear_and_free(dir_renames, struct dir_rename_entry, ent);
        free(dir_renames);
 
        free(pairs->queue);
@@ -3497,7 +3497,7 @@ static int merge_trees_internal(struct merge_options *opt,
                string_list_clear(entries, 1);
                free(entries);
 
-               hashmap_free_entries(&opt->priv->current_file_dir_set,
+               hashmap_clear_and_free(&opt->priv->current_file_dir_set,
                                        struct path_hashmap_entry, e);
 
                if (clean < 0) {
@@ -3517,17 +3517,6 @@ static int merge_trees_internal(struct merge_options *opt,
        return clean;
 }
 
-static struct commit_list *reverse_commit_list(struct commit_list *list)
-{
-       struct commit_list *next = NULL, *current, *backup;
-       for (current = list; current; current = backup) {
-               backup = current->next;
-               current->next = next;
-               next = current;
-       }
-       return next;
-}
-
 /*
  * Merge the commits h1 and h2, returning a flag (int) indicating the
  * cleanness of the merge.  Also, if opt->priv->call_depth, create a