Imported Upstream version 1.4
[debian/gzip] / lib / fchown-stub.c
diff --git a/lib/fchown-stub.c b/lib/fchown-stub.c
new file mode 100644 (file)
index 0000000..6be750b
--- /dev/null
@@ -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;
+}