constants: export O_NONBLOCK
Signed-off-by: Fedor Indutny <fedor@indutny.com>
This commit is contained in:
parent
a960d1707a
commit
00890e43fb
@ -27,11 +27,14 @@
|
|||||||
#if !defined(_MSC_VER)
|
#if !defined(_MSC_VER)
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#endif
|
#endif
|
||||||
#include <fcntl.h>
|
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
|
|
||||||
|
// O_NONBLOCK is not exported, unless _XOPEN_SOURCE is set
|
||||||
|
#define _XOPEN_SOURCE 500
|
||||||
|
#include <fcntl.h>
|
||||||
|
|
||||||
#if HAVE_OPENSSL
|
#if HAVE_OPENSSL
|
||||||
# include <openssl/ssl.h>
|
# include <openssl/ssl.h>
|
||||||
#endif
|
#endif
|
||||||
@ -110,6 +113,10 @@ void DefineConstants(Handle<Object> target) {
|
|||||||
NODE_DEFINE_CONSTANT(target, O_DIRECT);
|
NODE_DEFINE_CONSTANT(target, O_DIRECT);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef O_NONBLOCK
|
||||||
|
NODE_DEFINE_CONSTANT(target, O_NONBLOCK);
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef S_IRWXU
|
#ifdef S_IRWXU
|
||||||
NODE_DEFINE_CONSTANT(target, S_IRWXU);
|
NODE_DEFINE_CONSTANT(target, S_IRWXU);
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user