+#ifdef HAVE_CHFLAGS
+ }
+ /* finally restore original file flags */
+ if (chflags(attr->olname, s.st_flags) < 0) {
+ Qmsg2(jcr, M_ERROR, 0, _("Could not restore file flags for file %s: ERR=%s\n"),
+ attr->olname, be.bstrerror());
+ }
+ } else {
+ Qmsg2(jcr, M_ERROR, 0, _("Could not reset file flags for file %s: ERR=%s\n"),
+ attr->olname, be.bstrerror());
+ }
+ } else {
+ Qmsg3(jcr, M_ERROR, 0, _("Could not hard link %s -> %s: ERR=%s\n"),
+ attr->ofname, attr->olname, be.bstrerror());
+ return CF_ERROR;
+ }
+#endif /* HAVE_CHFLAGS */
+