author | Junio C Hamano <gitster@pobox.com> | |
Thu, 16 Dec 2010 20:51:05 +0000 (12:51 -0800) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Thu, 16 Dec 2010 20:51:05 +0000 (12:51 -0800) |
* nd/extended-sha1-relpath:
get_sha1: teach ":$n:<path>" the same relative path logic
get_sha1: support relative path ":path" syntax
Make prefix_path() return char* without const
Conflicts:
sha1_name.c
get_sha1: teach ":$n:<path>" the same relative path logic
get_sha1: support relative path ":path" syntax
Make prefix_path() return char* without const
Conflicts:
sha1_name.c
1 | 2 | |||
---|---|---|---|---|
cache.h | patch | | diff1 | | diff2 | | blob | history |
setup.c | patch | | diff1 | | diff2 | | blob | history |
sha1_name.c | patch | | diff1 | | diff2 | | blob | history |
diff --cc cache.h
Simple merge
diff --cc setup.c
Simple merge
diff --cc sha1_name.c
index 2c3a5fb363ff9b11a971b45e85819b2c0aaad157,207405688bb919363c0fdde31083f2e57d26e050..8f49279642bf1aa8ce74fee351772e3fb28a73c4
--- 1/sha1_name.c
--- 2/sha1_name.c
+++ b/sha1_name.c
if (name[0] == ':') {
int stage = 0;
struct cache_entry *ce;
+ char *new_path = NULL;
int pos;
if (namelen > 2 && name[1] == '/')
+ /* don't need mode for commit */
return get_sha1_oneline(name + 2, sha1);
if (namelen < 3 ||
name[2] != ':' ||
break;
if (ce_stage(ce) == stage) {
hashcpy(sha1, ce->sha1);
+ oc->mode = ce->ce_mode;
+ free(new_path);
return 0;
}
pos++;