summaryrefslogtreecommitdiff
path: root/ifuncs.h
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2009-01-03 08:53:59 -0800
committerWayne Davison <wayned@samba.org>2009-01-03 08:53:59 -0800
commit09ca0d15d31d93a5964a1db4c387879f31c22831 (patch)
treea966cbf8f02b8796d5c8d9f66e3c533ad97a4b41 /ifuncs.h
parentc43c66125e8fd35896a358ccce9687ebcfe82dc5 (diff)
downloadrsync-09ca0d15d31d93a5964a1db4c387879f31c22831.tar.gz
Added init_stat_x() to avoid duplication of acl/xattr init code.
Diffstat (limited to 'ifuncs.h')
-rw-r--r--ifuncs.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/ifuncs.h b/ifuncs.h
index 0fe900a3..8c128d58 100644
--- a/ifuncs.h
+++ b/ifuncs.h
@@ -66,3 +66,14 @@ d_name(struct dirent *di)
return di->d_name;
#endif
}
+
+static inline void
+init_stat_x(stat_x *sx_p)
+{
+#ifdef SUPPORT_ACLS
+ sx_p->acc_acl = sx_p->def_acl = NULL;
+#endif
+#ifdef SUPPORT_XATTRS
+ sx_p->xattr = NULL;
+#endif
+}