summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ruby/nxt_ruby_stream_io.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/ruby/nxt_ruby_stream_io.c b/src/ruby/nxt_ruby_stream_io.c
index 69bf289e..82ad3908 100644
--- a/src/ruby/nxt_ruby_stream_io.c
+++ b/src/ruby/nxt_ruby_stream_io.c
@@ -25,7 +25,9 @@ nxt_ruby_stream_io_input_init(void)
{
VALUE stream_io;
- stream_io = rb_define_class("NGINX_Unit_Stream_IO_Read", rb_cData);
+ stream_io = rb_define_class("NGINX_Unit_Stream_IO_Read", rb_cObject);
+
+ rb_undef_alloc_func(stream_io);
rb_gc_register_address(&stream_io);
@@ -46,7 +48,9 @@ nxt_ruby_stream_io_error_init(void)
{
VALUE stream_io;
- stream_io = rb_define_class("NGINX_Unit_Stream_IO_Error", rb_cData);
+ stream_io = rb_define_class("NGINX_Unit_Stream_IO_Error", rb_cObject);
+
+ rb_undef_alloc_func(stream_io);
rb_gc_register_address(&stream_io);