Commit Diff


commit - 0c4004e3b4aebeca63f9345737174e8fbe69abb7
commit + 9aceaadf35fc979f62e0a6761e967d2089f2103c
blob - 5fe931f9c74dc53f1a6814a342b8eefc7d80f439
blob + 50af4bbdfaba1517957e9e217dbfbdb2f9d71b17
--- lib/repository.c
+++ lib/repository.c
@@ -603,7 +603,7 @@ got_repo_open(struct got_repository **repop, const cha
 		if (err == NULL)
 			break;
 		if (err->code != GOT_ERR_NOT_GIT_REPO)
-			break;
+			goto done;
 		if (path[0] == '/' && path[1] == '\0') {
 			if (tried_root) {
 				err = got_error(GOT_ERR_NOT_GIT_REPO);