From e3fa723f998c94d01dbee6559b61828a75713ced Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Thu, 3 Jan 2008 09:13:39 +0000 Subject: [PATCH] Check for HAVE_LCHOWN (#505887) 2008-01-03 Alexander Larsson * glocalfileinfo.c: Check for HAVE_LCHOWN (#505887) svn path=/trunk/; revision=6236 --- gio/ChangeLog | 5 +++++ gio/glocalfileinfo.c | 2 ++ 2 files changed, 7 insertions(+) diff --git a/gio/ChangeLog b/gio/ChangeLog index f1a7e6d..94a9db6 100644 --- a/gio/ChangeLog +++ b/gio/ChangeLog @@ -1,5 +1,10 @@ 2008-01-03 Alexander Larsson + * glocalfileinfo.c: + Check for HAVE_LCHOWN (#505887) + +2008-01-03 Alexander Larsson + * gfileinfo.h: * glocalfileinfo.c: Add define for selinux context attribute. diff --git a/gio/glocalfileinfo.c b/gio/glocalfileinfo.c index 1f9cc8f..eff0129 100644 --- a/gio/glocalfileinfo.c +++ b/gio/glocalfileinfo.c @@ -1760,9 +1760,11 @@ set_unix_uid_gid (char *filename, else gid = -1; +#ifdef HAVE_LCHOWN if (flags & G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS) res = lchown (filename, uid, gid); else +#endif res = chown (filename, uid, gid); if (res == -1) -- 2.7.4