From d5ca067c7bb47081c169ff8b0213c73418f0525e Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Thu, 17 Feb 2011 23:13:46 -0500 Subject: add portable lchown (trivial to support and a few ancient things want it..) --- src/stat/lchmod.c | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 src/stat/lchmod.c (limited to 'src/stat/lchmod.c') diff --git a/src/stat/lchmod.c b/src/stat/lchmod.c new file mode 100644 index 00000000..c35f5861 --- /dev/null +++ b/src/stat/lchmod.c @@ -0,0 +1,7 @@ +#include +#include + +int lchmod(const char *path, mode_t mode) +{ + return fchmodat(AT_FDCWD, path, mode, AT_SYMLINK_NOFOLLOW); +} -- cgit v1.2.1