diff options
author | Bruno Haible <bruno@clisp.org> | 2009-09-06 22:36:55 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2009-09-06 22:36:55 +0200 |
commit | dd62ffcdad44eac2bc21f57a98bf1a57c893f989 (patch) | |
tree | 575d217fc9c88a19474fa1091ad3e99bd9b29dc8 | |
parent | 39dcff84b285160052e0bb26bd51411b89a37e33 (diff) | |
download | gnulib-dd62ffcdad44eac2bc21f57a98bf1a57c893f989.tar.gz |
Set errno to ENOSYS when a function is entirely unsupported.
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | lib/chown.c | 2 | ||||
-rw-r--r-- | lib/lchown.c | 2 | ||||
-rw-r--r-- | modules/chown | 1 |
4 files changed, 10 insertions, 3 deletions
@@ -1,5 +1,13 @@ 2009-09-06 Bruno Haible <bruno@clisp.org> + Set errno to ENOSYS when a function is entirely unsupported. + * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Set errno to ENOSYS instead of + EOPNOTSUPP. + * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise. + * modules/chown (Depends-on): Remove errno. + +2009-09-06 Bruno Haible <bruno@clisp.org> + * doc/posix-headers/fcntl.texi (AT_*): Mention affected platforms. 2009-09-06 Bruno Haible <bruno@clisp.org> diff --git a/lib/chown.c b/lib/chown.c index cca1d7f3c6..b851cbc4c0 100644 --- a/lib/chown.c +++ b/lib/chown.c @@ -103,7 +103,7 @@ rpl_chown (const char *file, uid_t uid, gid_t gid) return chown (file, uid, gid); #else /* !HAVE_CHOWN */ - errno = EOPNOTSUPP; + errno = ENOSYS; return -1; #endif } diff --git a/lib/lchown.c b/lib/lchown.c index 10ba1c9e5c..8cf10dd0c2 100644 --- a/lib/lchown.c +++ b/lib/lchown.c @@ -52,7 +52,7 @@ lchown (const char *file, uid_t uid, gid_t gid) return chown (file, uid, gid); #else /* !HAVE_CHOWN */ - errno = EOPNOTSUPP; + errno = ENOSYS; return -1; #endif } diff --git a/modules/chown b/modules/chown index 7cd07f590b..cf9921089b 100644 --- a/modules/chown +++ b/modules/chown @@ -7,7 +7,6 @@ lib/fchown-stub.c m4/chown.m4 Depends-on: -errno open unistd sys_stat |