]> arthur.ath.cx Git - bup.git/blobdiff - lib/bup/git.py
git: close PackIdxList on init failures
[bup.git] / lib / bup / git.py
index c038fd1587b2abeb5ea920db7e476cf32194de92..3608f183715d4981f1dacb11adcd93a6c56817ae 100644 (file)
@@ -539,7 +539,11 @@ class PackIdxList:
         self.do_bloom = False
         self.bloom = None
         self.ignore_midx = ignore_midx
-        self.refresh()
+        try:
+            self.refresh()
+        except BaseException as ex:
+            with pending_raise(ex):
+                self.close()
 
     def close(self):
         global _mpi_count