2 Bacula(R) - The Network Backup Solution
4 Copyright (C) 2000-2015 Kern Sibbald
5 Copyright (C) 2004-2014 Free Software Foundation Europe e.V.
7 The original author of Bacula is Kern Sibbald, with contributions
8 from many others, a complete list can be found in the file AUTHORS.
10 You may use this file and others of this release according to the
11 license defined in the LICENSE file, which includes the Affero General
12 Public License, v3.0 ("AGPLv3") and some additional permissions and
13 terms pursuant to its AGPLv3 Section 7.
15 This notice must be preserved when any source code is
16 conveyed and/or propagated.
18 Bacula(R) is a registered trademark of Kern Sibbald.
21 #ifndef BACULA_XATTR_H_
22 #define BACULA_XATTR_H_
24 #if defined(HAVE_LINUX_OS)
25 #define BXATTR_ENOTSUP EOPNOTSUPP
26 #elif defined(HAVE_DARWIN_OS)
27 #define BXATTR_ENOTSUP ENOTSUP
28 #elif defined(HAVE_HURD_OS)
29 #define BXATTR_ENOTSUP ENOTSUP
33 * Magic used in the magic field of the xattr struct.
34 * This way we can see we encounter a valid xattr struct.
36 #define XATTR_MAGIC 0x5C5884
39 * Internal representation of an extended attribute.
45 uint32_t value_length;
50 * Internal representation of an extended attribute hardlinked file.
52 struct xattr_link_cache_entry_t {
57 #define BXATTR_FLAG_SAVE_NATIVE 0x01
58 #define BXATTR_FLAG_RESTORE_NATIVE 0x02
61 * Internal tracking data.
64 uint32_t flags; /* See BXATTR_FLAG_* */
69 uint32_t content_length;
73 #define MAX_XATTR_LENGTH (1 * 1024 * 1024) /* 1 Mb */
75 #define XATTR_BUFSIZ 1024
77 #endif /* BACULA_XATTR_H_ */