ext/io/nonblock/nonblock.c in io-nonblock-0.3.0 vs ext/io/nonblock/nonblock.c in io-nonblock-0.3.1
- old
+ new
@@ -195,9 +195,13 @@
#endif
void
Init_nonblock(void)
{
+#ifdef HAVE_RB_EXT_RACTOR_SAFE
+ rb_ext_ractor_safe(true);
+#endif
+
#ifndef RUBY_IO_NONBLOCK_METHODS
rb_define_method(rb_cIO, "nonblock?", rb_io_nonblock_p, 0);
rb_define_method(rb_cIO, "nonblock=", rb_io_nonblock_set, 1);
#endif