2
2
mirror of https://github.com/octoleo/restic.git synced 2024-11-24 05:37:37 +00:00

report result of delete operation after failed upload

This commit is contained in:
Michael Eischer 2021-03-08 21:54:17 +01:00
parent 95b7f8dd81
commit e1bb2129ad

View File

@ -84,6 +84,9 @@ func (be *RetryBackend) Save(ctx context.Context, h restic.Handle, rd restic.Rew
rerr := be.Backend.Remove(ctx, h) rerr := be.Backend.Remove(ctx, h)
if rerr != nil { if rerr != nil {
debug.Log("Remove(%v) returned error: %v", h, err) debug.Log("Remove(%v) returned error: %v", h, err)
if be.Report != nil {
be.Report(fmt.Sprintf("Delete-failed-Save(%v)", h), err, time.Duration(0))
}
} }
// return original error // return original error