diff options
author | ben <ben@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2002-09-20 00:51:00 +0000 |
---|---|---|
committer | ben <ben@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2002-09-20 00:51:00 +0000 |
commit | 727ed4ecc5a9ebc4db1c3e550f9a989d29637fb3 (patch) | |
tree | 7f68203e69f43163ec707aebbdd967a16aa21c81 | |
parent | 46d2fadcbf46fe88ea46c0fee126c009d17a95db (diff) | |
download | rdiff-backup-727ed4ecc5a9ebc4db1c3e550f9a989d29637fb3.tar.gz |
Changed resume code - unpickling may cause variety of errors
git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/trunk@209 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109
-rw-r--r-- | rdiff-backup/rdiff_backup/robust.py | 5 | ||||
-rw-r--r-- | rdiff-backup/src/robust.py | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/rdiff-backup/rdiff_backup/robust.py b/rdiff-backup/rdiff_backup/robust.py index 5726914..cecd33c 100644 --- a/rdiff-backup/rdiff_backup/robust.py +++ b/rdiff-backup/rdiff_backup/robust.py @@ -607,8 +607,9 @@ class Resume: data = fp.read() fp.close() try: result = cPickle.loads(data) - except cPickle.UnpicklingError: - raise ResumeException("Bad pickle at %s" % (checkpoint_rp.path,)) + except Exception, exc: + raise ResumeException("Bad pickle at %s: %s" % + (checkpoint_rp.path, exc)) return result def ResumeCheck(cls): diff --git a/rdiff-backup/src/robust.py b/rdiff-backup/src/robust.py index 5726914..cecd33c 100644 --- a/rdiff-backup/src/robust.py +++ b/rdiff-backup/src/robust.py @@ -607,8 +607,9 @@ class Resume: data = fp.read() fp.close() try: result = cPickle.loads(data) - except cPickle.UnpicklingError: - raise ResumeException("Bad pickle at %s" % (checkpoint_rp.path,)) + except Exception, exc: + raise ResumeException("Bad pickle at %s: %s" % + (checkpoint_rp.path, exc)) return result def ResumeCheck(cls): |