OSDN Git Service

builtin/difftool.c: drop hashmap_cmp_fn cast
[git-core/git.git] / sequencer.c
index 5282fb8..98cdfe7 100644 (file)
@@ -1,4 +1,5 @@
 #include "cache.h"
+#include "config.h"
 #include "lockfile.h"
 #include "sequencer.h"
 #include "dir.h"
@@ -1211,8 +1212,7 @@ struct todo_list {
 static void todo_list_release(struct todo_list *todo_list)
 {
        strbuf_release(&todo_list->buf);
-       free(todo_list->items);
-       todo_list->items = NULL;
+       FREE_AND_NULL(todo_list->items);
        todo_list->nr = todo_list->alloc = 0;
 }
 
@@ -2130,8 +2130,8 @@ cleanup_head_ref:
                        if (read_oneliner(&buf, rebase_path_orig_head(), 0) &&
                            !get_sha1(buf.buf, orig.hash) &&
                            !get_sha1("HEAD", head.hash)) {
-                               diff_tree_sha1(orig.hash, head.hash,
-                                              "", &log_tree_opt.diffopt);
+                               diff_tree_oid(&orig, &head, "",
+                                             &log_tree_opt.diffopt);
                                log_tree_diff_flush(&log_tree_opt);
                        }
                }