From e0d0dd8aec489b8cfb1e59df72b8d9c5210504ce Mon Sep 17 00:00:00 2001 From: Marco van Wieringen Date: Tue, 25 Nov 2014 21:58:46 +0100 Subject: [PATCH] Don't count failed restored files. --- src/filed/fd_plugins.c | 3 ++- src/filed/restore.c | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/filed/fd_plugins.c b/src/filed/fd_plugins.c index e036043e530..dc9cde3314c 100644 --- a/src/filed/fd_plugins.c +++ b/src/filed/fd_plugins.c @@ -1152,7 +1152,8 @@ int plugin_create_file(JCR *jcr, ATTR *attr, BFILE *bfd, int replace) Dmsg0(dbglvl, "call bopen\n"); status = bopen(bfd, attr->ofname, flags, S_IRUSR | S_IWUSR, attr->statp.st_rdev); - Dmsg1(dbglvl, "bopen status=%d\n", stat); + Dmsg1(dbglvl, "bopen status=%d\n", status); + if (status < 0) { berrno be; be.set_errno(bfd->berrno); diff --git a/src/filed/restore.c b/src/filed/restore.c index be26919c299..52d35242845 100644 --- a/src/filed/restore.c +++ b/src/filed/restore.c @@ -599,6 +599,7 @@ void do_restore(JCR *jcr) Dmsg2(130, "Outfile=%s create_file status=%d\n", attr->ofname, status); switch (status) { case CF_ERROR: + break; case CF_SKIP: jcr->JobFiles++; break;