summaryrefslogtreecommitdiff
path: root/bin/pax/pax.h
diff options
context:
space:
mode:
Diffstat (limited to 'bin/pax/pax.h')
-rw-r--r--bin/pax/pax.h20
1 files changed, 19 insertions, 1 deletions
diff --git a/bin/pax/pax.h b/bin/pax/pax.h
index 1c85aaec837..17c625ea9dd 100644
--- a/bin/pax/pax.h
+++ b/bin/pax/pax.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: pax.h,v 1.20 2015/01/16 06:39:32 deraadt Exp $ */
+/* $OpenBSD: pax.h,v 1.21 2015/02/05 07:49:25 guenther Exp $ */
/* $NetBSD: pax.h,v 1.3 1995/03/21 09:07:41 cgd Exp $ */
/*-
@@ -211,6 +211,20 @@ typedef struct {
} FSUB;
/*
+ * Time data for a given file. This is usually embedded in a structure
+ * indexed by dev+ino, by name, by order in the archive, etc. set_attr()
+ * takes one of these and will only change the times or mode if the file
+ * at the given name has the indicated dev+ino.
+ */
+struct file_times {
+ ino_t ft_ino; /* inode number to verify */
+ time_t ft_mtime; /* times to set */
+ time_t ft_atime;
+ char *ft_name; /* name of file to set the times on */
+ dev_t ft_dev; /* device number to verify */
+};
+
+/*
* Format Specific Options List
*
* Used to pass format options to the format options handler
@@ -229,6 +243,10 @@ typedef struct oplist {
#define MINOR(x) minor(x)
#define TODEV(x, y) makedev((x), (y))
+#define FILEBITS (S_ISVTX | S_IRWXU | S_IRWXG | S_IRWXO)
+#define SETBITS (S_ISUID | S_ISGID)
+#define ABITS (FILEBITS | SETBITS)
+
/*
* General Defines
*/