]> arthur.barton.de Git - bup.git/blobdiff - cmd/save-cmd.py
cmd/save: if file.read() returns an error, don't abort.
[bup.git] / cmd / save-cmd.py
index 4477894fefa7035ede49a45d3c451a8cbe9784ee..c10c216c2274fbd9912597a91359ac579fc0fb59 100755 (executable)
@@ -241,7 +241,12 @@ for (transname,ent) in r.filter(extra, wantrecurse=wantrecurse_during):
                 add_error(e)
                 lastskip_name = ent.name
             else:
-                (mode, id) = hashsplit.split_to_blob_or_tree(w, [f], False)
+                try:
+                    (mode, id) = hashsplit.split_to_blob_or_tree(w, [f],
+                                            keep_boundaries=False)
+                except IOError, e:
+                    add_error('%s: %s' % (ent.name, e))
+                    lastskip_name = ent.name
         else:
             if stat.S_ISDIR(ent.mode):
                 assert(0)  # handled above