summaryrefslogtreecommitdiffstats
path: root/otherlibs/unix/open.c
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@inria.fr>1996-04-12 15:57:28 +0000
committerXavier Leroy <xavier.leroy@inria.fr>1996-04-12 15:57:28 +0000
commitee1266885025393876a3c42857881cd75b50f562 (patch)
tree4b8313e781c5d3be15af0c868dd01c7f7f1132ac /otherlibs/unix/open.c
parenta9aac029f688b5f71f748697dbea937c526faaae (diff)
Ajout de setitimer, setsockopt, inet_addr_any.
Suppression de fcntl, ajout de fonctions pour manipuler le mode non bloquant et le bit close on exec. Nettoyage des codes d'erreur (plus proches de POSIX). Nettoyages divers. git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@742 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'otherlibs/unix/open.c')
-rw-r--r--otherlibs/unix/open.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/otherlibs/unix/open.c b/otherlibs/unix/open.c
index 795a787fa..9c12eedc8 100644
--- a/otherlibs/unix/open.c
+++ b/otherlibs/unix/open.c
@@ -16,8 +16,12 @@
#include "unix.h"
#include <fcntl.h>
+#ifndef O_NONBLOCK
+#define O_NONBLOCK O_NDELAY
+#endif
+
static int open_flag_table[] = {
- O_RDONLY, O_WRONLY, O_RDWR, O_NDELAY, O_APPEND, O_CREAT, O_TRUNC, O_EXCL
+ O_RDONLY, O_WRONLY, O_RDWR, O_NONBLOCK, O_APPEND, O_CREAT, O_TRUNC, O_EXCL
};
value unix_open(path, flags, perm) /* ML */