提交 29f3b3de 编写于 作者: J Junio C Hamano

Make sure leading directories exist when pushing refs.

It does not matter if the only refs you push are directly
underneath heads and tags, but we forgot to make sure we have
leading directories so pushing tags/v0.99/1 would not have
worked.
Signed-off-by: NJunio C Hamano <junkio@cox.net>
上级 19614330
......@@ -106,6 +106,8 @@ static int update(const char *name,
return error("unpack should have generated %s, "
"but I can't find it!", new_hex);
safe_create_leading_directories(lock_name);
newfd = open(lock_name, O_CREAT | O_EXCL | O_WRONLY, 0666);
if (newfd < 0)
return error("unable to create %s (%s)",
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册