Code

Merge branch 'js/rerere'
[git.git] / merge-recursive.c
index 58f2cb4ed3e3cb9450ee1aaf4219f3c337342d02..ae7ae4cd2a9ce392945ad8ed27e4289c27ee24bd 100644 (file)
@@ -3,13 +3,6 @@
  * Fredrik Kuivinen.
  * The thieves were Alex Riesen and Johannes Schindelin, in June/July 2006
  */
-#include <stdarg.h>
-#include <string.h>
-#include <assert.h>
-#include <sys/wait.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <time.h>
 #include "cache.h"
 #include "cache-tree.h"
 #include "commit.h"
@@ -879,7 +872,7 @@ static int process_renames(struct path_list *a_renames,
                        struct diff_filespec src_other, dst_other;
                        int try_merge, stage = a_renames == renames1 ? 3: 2;
 
-                       remove_file(1, ren1_src, 1);
+                       remove_file(1, ren1_src, index_only);
 
                        hashcpy(src_other.sha1, ren1->src_entry->stages[stage].sha);
                        src_other.mode = ren1->src_entry->stages[stage].mode;
@@ -1279,7 +1272,7 @@ int main(int argc, char *argv[])
        struct commit *result, *h1, *h2;
 
        git_config(git_default_config); /* core.filemode */
-       original_index_file = getenv("GIT_INDEX_FILE");
+       original_index_file = getenv(INDEX_ENVIRONMENT);
 
        if (!original_index_file)
                original_index_file = xstrdup(git_path("index"));