summaryrefslogtreecommitdiff
path: root/gnu/fchown-stub.c
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/fchown-stub.c')
-rw-r--r--gnu/fchown-stub.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/gnu/fchown-stub.c b/gnu/fchown-stub.c
new file mode 100644
index 0000000..62b6969
--- /dev/null
+++ b/gnu/fchown-stub.c
@@ -0,0 +1,16 @@
+#include <config.h>
+
+#include <sys/types.h>
+#include <errno.h>
+
+/* A trivial substitute for 'fchown'.
+
+ DJGPP 2.03 and earlier (and perhaps later) don't have 'fchown',
+ so we pretend no-one has permission for this operation. */
+
+int
+fchown (int fd, uid_t uid, gid_t gid)
+{
+ errno = EPERM;
+ return -1;
+}