Catch UnpicklingError when loading the mtimedb (reported by marienz).
authorZac Medico <zmedico@gentoo.org>
Mon, 9 Oct 2006 20:26:21 +0000 (20:26 -0000)
committerZac Medico <zmedico@gentoo.org>
Mon, 9 Oct 2006 20:26:21 +0000 (20:26 -0000)
svn path=/main/trunk/; revision=4638

pym/portage.py

index 579c3f5a06c37921a88382bb07e64742a376a095..c0286ca09c0de8358fc7721e10fd9cbc4deb3510 100644 (file)
@@ -6897,7 +6897,7 @@ class MtimeDB(dict):
                        d = mypickle.load()
                        f.close()
                        del f
-               except (IOError, OSError, EOFError):
+               except (IOError, OSError, EOFError, cPickle.UnpicklingError):
                        d = {}
 
                if "old" in d: