diff options
author | normal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-06-22 08:47:12 +0000 |
---|---|---|
committer | normal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-06-22 08:47:12 +0000 |
commit | 45765e94d90d407b4190573e47d395e7c2b4a04e (patch) | |
tree | 32c9f9c390a959b3d9a6db954aa1b4b8276ea4e0 /dir.c | |
parent | 3839734b945e464b678a9718fdce3c05e9e7f613 (diff) | |
download | ruby-45765e94d90d407b4190573e47d395e7c2b4a04e.tar.gz |
dir.c: define O_CLOEXEC for older systems
SuSE 10 has openat(), but not O_CLOEXEC
Reported-by: wangpeiwen
[ruby-core:87591] [Bug #14864]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63720 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'dir.c')
-rw-r--r-- | dir.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -24,6 +24,10 @@ #include <unistd.h> #endif +#ifndef O_CLOEXEC +# define O_CLOEXEC 0 +#endif + #ifndef USE_OPENDIR_AT # if defined(HAVE_FDOPENDIR) && defined(HAVE_DIRFD) && \ defined(HAVE_OPENAT) && defined(HAVE_FSTATAT) |