diff --git a/git_cache.py b/git_cache.py index c33252035..89f7f6d79 100755 --- a/git_cache.py +++ b/git_cache.py @@ -308,6 +308,8 @@ class Mirror(object): tempdir) if code: return False + # A quick validation that all references are valid. + self.RunGit(['for-each-ref'], cwd=tempdir) except Exception as e: self.print('Encountered error: %s' % str(e), file=sys.stderr) gclient_utils.rmtree(tempdir)