home *** CD-ROM | disk | FTP | other *** search
- /*
- * fcntl() emulation for MiNT; written by Eric R. Smith and placed
- * in the public domain
- */
-
- #include <errno.h>
- #include <mintbind.h>
- #include <fcntl.h>
-
- extern int __mint; /* MiNT version */
-
- int fcntl(f, cmd, arg)
- int f, cmd;
- void *arg;
- {
- long r;
-
- if (__mint) {
- r = Fcntl(f, arg, cmd);
- }
- else
- r = -EINVAL;
- if (r < 0) {
- errno = -r;
- r = -1;
- }
- return r;
- }
-