Commit fbcc8bd1 by kdj0c Committed by Patrick Steinhardt

submodule sync, fix edge case with submodule sync on empty repo

parent 42e0bed2
......@@ -2170,7 +2170,7 @@ static int lookup_default_remote(git_remote **remote, git_repository *repo)
int error = lookup_head_remote(remote, repo);
/* if that failed, use 'origin' instead */
if (error == GIT_ENOTFOUND)
if (error == GIT_ENOTFOUND || error == GIT_EUNBORNBRANCH)
error = git_remote_lookup(remote, repo, "origin");
if (error == GIT_ENOTFOUND)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment