- /*
- * AFS is a non OS specific filesystem so see if this path is on an AFS filesystem
- * and retrieve its ACL if it is.
+ /**
+ * AFS is a non OS specific filesystem so see if this path is on an AFS filesystem
+ * Set the BACL_FLAG_SAVE_AFS flag if it is. If not set the BACL_FLAG_SAVE_NATIVE flag.
+ */
+ if (fstype_equals(jcr->last_fname, "afs")) {
+ jcr->acl_data->flags |= BACL_FLAG_SAVE_AFS;
+ } else {
+ jcr->acl_data->flags |= BACL_FLAG_SAVE_NATIVE;
+ }
+#else
+ jcr->acl_data->flags |= BACL_FLAG_SAVE_NATIVE;
+#endif
+
+ /**
+ * Save that we started scanning a new filesystem.
+ */
+ jcr->acl_data->current_dev = ff_pkt->statp.st_dev;
+ }
+
+#if defined(HAVE_AFS_ACL)
+ /**
+ * See if the BACL_FLAG_SAVE_AFS flag is set which lets us know if we should
+ * save AFS ACLs.