summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-05-12 09:36:57 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-05-12 09:36:57 +0000
commit952fa45645a05601034130fcd36a0217af924605 (patch)
tree349b71c9e43bf3b2c6eccce1e6f8be9d073a0af4 /spec
parent6e4d65cdc61cfa6aaaadbf0b923059e6636ba64a (diff)
unistd.h is only available when HAVE_UNISTD_H is 1
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58679 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'spec')
-rw-r--r--spec/rubyspec/optional/capi/ext/thread_spec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/rubyspec/optional/capi/ext/thread_spec.c b/spec/rubyspec/optional/capi/ext/thread_spec.c
index 5ea96fe3d6..78e8183129 100644
--- a/spec/rubyspec/optional/capi/ext/thread_spec.c
+++ b/spec/rubyspec/optional/capi/ext/thread_spec.c
@@ -4,7 +4,9 @@
#include <math.h>
#include <errno.h>
+#if HAVE_UNISTD_H
#include <unistd.h>
+#endif
#ifdef __cplusplus
extern "C" {