author | Junio C Hamano <junkio@cox.net> | |
Sun, 14 May 2006 23:58:44 +0000 (16:58 -0700) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sun, 14 May 2006 23:58:44 +0000 (16:58 -0700) |
* lt/oneway:
Simplify "git reset --hard"
Allow one-way tree merge to remove old files
Simplify "git reset --hard"
Allow one-way tree merge to remove old files
1 | 2 | |||
---|---|---|---|---|
read-tree.c | patch | | diff1 | | diff2 | | blob | history |
diff --cc read-tree.c
index c25385d79f605c74ae9e9cde06225f0a4c834f00,11157f42426d7f1783420e1a5fa72379ee759e6a..7c830312c403c328dc278d57fecb8d4381cbf2c3
--- 1/read-tree.c
--- 2/read-tree.c
+++ b/read-tree.c
return error("Cannot do a oneway merge of %d trees",
merge_size);
- if (!a)
+ if (!a) {
+ invalidate_ce_path(old);
- return 0;
+ return deleted_entry(old, NULL);
+ }
if (old && same(old, a)) {
return keep_entry(old);
}