summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2020-11-22 19:10:58 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2020-11-22 19:10:58 +0900
commit7c879cbb3f24c742e0d3226c39d413abe7519205 (patch)
tree25c59f92274ef54136e1f1b5d014d34c69f73fb6
parent75d48a533d01eeb1bb5e6761484a4dece9408fc1 (diff)
Suppress a unused-variable warning
-rw-r--r--spec/ruby/optional/capi/ext/io_spec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/ruby/optional/capi/ext/io_spec.c b/spec/ruby/optional/capi/ext/io_spec.c
index 59613c1..73e6804 100644
--- a/spec/ruby/optional/capi/ext/io_spec.c
+++ b/spec/ruby/optional/capi/ext/io_spec.c
@@ -203,7 +203,9 @@ VALUE io_spec_rb_io_close(VALUE self, VALUE io) {
VALUE io_spec_rb_io_set_nonblock(VALUE self, VALUE io) {
rb_io_t* fp;
+#ifdef F_GETFL
int flags;
+#endif
GetOpenFile(io, fp);
rb_io_set_nonblock(fp);
#ifdef F_GETFL