libtar: support backing up and restoring new Android user.* xattr
Support for backing up and restoring user.default, user.inode_cache, and
user.inode_code_cache xattrs introduced in Android 7.x
Change-Id: I6e0aa7fc9cd30ed004ef28ebb58d60a82e518123
diff --git a/libtar/libtar.h b/libtar/libtar.h
index 4d92124..2d0a3d3 100644
--- a/libtar/libtar.h
+++ b/libtar/libtar.h
@@ -74,6 +74,9 @@
#endif
int has_cap_data;
struct vfs_cap_data cap_data;
+ int has_user_default;
+ int has_user_cache;
+ int has_user_code_cache;
};
@@ -120,6 +123,7 @@
#define TAR_USE_NUMERIC_ID 256 /* favor numeric owner over names */
#define TAR_STORE_EXT4_POL 512 /* store ext4 crypto policy */
#define TAR_STORE_POSIX_CAP 1024 /* store posix file capabilities */
+#define TAR_STORE_ANDROID_USER_XATTR 2048 /* store android user.* xattr */
/* this is obsolete - it's here for backwards-compatibility only */
#define TAR_IGNORE_MAGIC 0