]> asedeno.scripts.mit.edu Git - git.git/commitdiff
Merge branch 'lt/oneway' into next
authorJunio C Hamano <junkio@cox.net>
Mon, 15 May 2006 07:48:00 +0000 (00:48 -0700)
committerJunio C Hamano <junkio@cox.net>
Mon, 15 May 2006 07:48:00 +0000 (00:48 -0700)
* lt/oneway:
  read-tree -u one-way merge fix to check out locally modified paths.

read-tree.c

index 7c830312c403c328dc278d57fecb8d4381cbf2c3..3f0233954725397c8783f544f2f8d27125b82a13 100644 (file)
@@ -723,6 +723,9 @@ static int oneway_merge(struct cache_entry **src)
                return deleted_entry(old, NULL);
        }
        if (old && same(old, a)) {
+               struct stat st;
+               if (lstat(old->name, &st) || ce_match_stat(old, &st, 1))
+                       old->ce_flags |= htons(CE_UPDATE);
                return keep_entry(old);
        }
        return merged_entry(a, NULL);