diff --git a/CHANGELOG.md b/CHANGELOG.md index 23669780..927f3e93 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ * Add Ruby 3.0 to the cross compile list * Fix segfault when asking if client was dead after closing it. Fixes #519. +* Mark `alloc` function as undefined on `TinyTds::Result`. Fixes #515. ## 2.1.5 diff --git a/ext/tiny_tds/result.c b/ext/tiny_tds/result.c index 98886c23..52d32230 100644 --- a/ext/tiny_tds/result.c +++ b/ext/tiny_tds/result.c @@ -584,6 +584,7 @@ void init_tinytds_result() { cDate = rb_const_get(rb_cObject, rb_intern("Date")); /* Define TinyTds::Result */ cTinyTdsResult = rb_define_class_under(mTinyTds, "Result", rb_cObject); + rb_undef_alloc_func(cTinyTdsResult); /* Define TinyTds::Result Public Methods */ rb_define_method(cTinyTdsResult, "fields", rb_tinytds_result_fields, 0); rb_define_method(cTinyTdsResult, "each", rb_tinytds_result_each, -1);