diff options
Diffstat (limited to 'builtin/mktree.c')
-rw-r--r-- | builtin/mktree.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin/mktree.c b/builtin/mktree.c index bb76b469fd..94e82b8504 100644 --- a/builtin/mktree.c +++ b/builtin/mktree.c @@ -7,6 +7,7 @@ #include "quote.h" #include "tree.h" #include "parse-options.h" +#include "object-store.h" static struct treeent { unsigned mode; @@ -97,7 +98,7 @@ static void mktree_line(char *buf, size_t len, int nul_term_line, int allow_miss *ntr++ = 0; /* now at the beginning of SHA1 */ - path = ntr + 41; /* at the beginning of name */ + path = (char *)p + 1; /* at the beginning of name */ if (!nul_term_line && path[0] == '"') { struct strbuf p_uq = STRBUF_INIT; if (unquote_c_style(&p_uq, path, NULL)) |