From f75870beac41d046d0abc4cd1c03621a7a460f5a Mon Sep 17 00:00:00 2001 From: Mani Chandel Date: Wed, 3 Sep 2014 13:54:48 +0530 Subject: [PATCH] Change implementation of cleanup in case of clone failure during "repo init" Fix includes: 1. It deletes only .repo/repo instead of the whole .repo repository. Bug: Issue 161 Change-Id: I1ab8caa7538fec5e6206d1b029f63bd3f60dedcd --- repo | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/repo b/repo index 3fd0166e..6338483b 100755 --- a/repo +++ b/repo @@ -738,7 +738,7 @@ def main(orig_args): try: _Init(args) except CloneFailure: - shutil.rmtree(repodir, ignore_errors=True) + shutil.rmtree(os.path.join(repodir, S_repo), ignore_errors=True) sys.exit(1) repo_main, rel_repo_dir = _FindRepo() else: