This fixes a minor memory leak in libobjc. I should probably also submit
this to gcc...
2003-08-31 Adam Fedor <[EMAIL PROTECTED]>
* selector.c (__objc_register_instance_methods_to_class): Free
new_list if not used.
Index: selector.c
===================================================================
RCS file: /cvsroot/gnustep/gnustep/dev-libs/libobjc/selector.c,v
retrieving revision 1.3
diff -u -p -r1.3 selector.c
--- selector.c 23 Feb 2003 03:48:41 -0000 1.3
+++ selector.c 1 Sep 2003 03:36:06 -0000
@@ -148,6 +148,8 @@ void __objc_register_instance_methods_to
new_list->method_next = class->class_pointer->methods;
class->class_pointer->methods = new_list;
}
+ else
+ objc_free(new_list);
__objc_update_dispatch_table_for_class (class->class_pointer);
}
_______________________________________________
Bug-gnustep mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-gnustep