From: Jarkko Hietaniemi Date: Wed, 15 Mar 2000 22:00:57 +0000 (+0000) Subject: Add missing Windows O_ constants. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=521fa0bb891e5ba08b4c7665151d080be4968077;p=p5sagit%2Fp5-mst-13.2.git Add missing Windows O_ constants. p4raw-id: //depot/cfgperl@5755 --- diff --git a/ext/Fcntl/Fcntl.pm b/ext/Fcntl/Fcntl.pm index 171538e..92103a1 100644 --- a/ext/Fcntl/Fcntl.pm +++ b/ext/Fcntl/Fcntl.pm @@ -118,11 +118,15 @@ $VERSION = "1.03"; O_NDELAY O_NOCTTY O_NOFOLLOW + O_NOINHERIT O_NONBLOCK + O_RANDOM + O_RAW O_RDONLY O_RDWR O_RSRC O_RSYNC + O_SEQUENTIAL O_SHLOCK O_SYNC O_TEMPORARY diff --git a/ext/Fcntl/Fcntl.xs b/ext/Fcntl/Fcntl.xs index 8d4a073..b597e03 100644 --- a/ext/Fcntl/Fcntl.xs +++ b/ext/Fcntl/Fcntl.xs @@ -46,7 +46,7 @@ constant(char *name, int arg) errno = 0; switch (*name) { case '_': - if (strEQ(name, "_S_IFMT")) /* Yes, _S_IFMT. */ + if (strEQ(name, "_S_IFMT")) /* Yes, on name _S_IFMT return S_IFMT. */ #ifdef S_IFMT return S_IFMT; #else @@ -476,12 +476,30 @@ constant(char *name, int arg) #else goto not_there; #endif + if (strEQ(name, "O_NOINHERIT")) +#ifdef O_NOINHERIT + return O_NOINHERIT; +#else + goto not_there; +#endif if (strEQ(name, "O_NONBLOCK")) #ifdef O_NONBLOCK return O_NONBLOCK; #else goto not_there; #endif + if (strEQ(name, "O_RANDOM")) +#ifdef O_RANDOM + return O_RANDOM; +#else + goto not_there; +#endif + if (strEQ(name, "O_RAW")) +#ifdef O_RAW + return O_RAW; +#else + goto not_there; +#endif if (strEQ(name, "O_RDONLY")) #ifdef O_RDONLY return O_RDONLY; @@ -500,6 +518,12 @@ constant(char *name, int arg) #else goto not_there; #endif + if (strEQ(name, "O_SEQUENTIAL")) +#ifdef O_SEQUENTIAL + return O_SEQUENTIAL; +#else + goto not_there; +#endif if (strEQ(name, "O_SHLOCK")) #ifdef O_SHLOCK return O_SHLOCK;