summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 5c553ea)
raw | patch | inline | side by side (parent: 5c553ea)
author | Junio C Hamano <junkio@cox.net> | |
Thu, 8 Feb 2007 07:41:43 +0000 (23:41 -0800) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Thu, 8 Feb 2007 07:41:43 +0000 (23:41 -0800) |
Otherwise "git remote add -t master -m master" without the
initial fetch would not work.
Signed-off-by: Junio C Hamano <junkio@cox.net>
initial fetch would not work.
Signed-off-by: Junio C Hamano <junkio@cox.net>
refs.c | patch | blob | history |
index 7e07fc4cb5b6bc32f5c75211aff636421f9e14d5..f3579457ce91e87af42eb6cb68aa791b91d66193 100644 (file)
--- a/refs.c
+++ b/refs.c
if (logmsg && read_ref(ref_target, old_sha1))
hashclr(old_sha1);
+ if (safe_create_leading_directories(git_HEAD) < 0)
+ return error("unable to create directory for %s", git_HEAD);
+
#ifndef NO_SYMLINK_HEAD
if (prefer_symlink_refs) {
unlink(git_HEAD);