From d886bc6c48339448dce3a2a7ca5b372897400296 Mon Sep 17 00:00:00 2001 From: Alexander Neumann Date: Thu, 5 Oct 2017 20:39:53 +0200 Subject: [PATCH] Ignore invalid index files, print warning --- internal/repository/repository.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/internal/repository/repository.go b/internal/repository/repository.go index 96eb932d9..e2d870780 100644 --- a/internal/repository/repository.go +++ b/internal/repository/repository.go @@ -378,7 +378,8 @@ func (r *Repository) LoadIndex(ctx context.Context) error { worker := func(ctx context.Context, id restic.ID) error { idx, err := LoadIndex(ctx, r, id) if err != nil { - return err + fmt.Fprintf(os.Stderr, "%v, ignoring\n", err) + return nil } select {