From bcfcfedc3085afe83dd39e68994524cdfec39a67 Mon Sep 17 00:00:00 2001 From: Peter Zhu Date: Tue, 11 Nov 2025 14:09:59 -0500 Subject: Fix memory leak in invalidate_ccs_in_iclass_cc_tbl invalidate_ccs_in_iclass_cc_tbl deletes the ccs from the table but never frees it, causing memory to leak. --- vm_method.c | 1 + 1 file changed, 1 insertion(+) diff --git a/vm_method.c b/vm_method.c index bf04140cb7..179deb749d 100644 --- a/vm_method.c +++ b/vm_method.c @@ -563,6 +563,7 @@ invalidate_ccs_in_iclass_cc_tbl(VALUE value, void *data) { struct rb_class_cc_entries *ccs = (struct rb_class_cc_entries *)value; vm_cme_invalidate((rb_callable_method_entry_t *)ccs->cme); + xfree(ccs); return ID_TABLE_DELETE; } -- cgit v1.2.3