[Coldstuff] set_method_access bug in genesis

coldstuff@cold.org coldstuff@cold.org
Thu, 21 Mar 2002 21:05:56 -0500


There's a bug in set_method_access in Genesis which is causing errors to propagate incorrectly:

;catch any { catch any { .set_method_access('bad_method_name, 'bad_access_type); } with { return 'should_get_this; } } with { return 'should_not_get_this; }
=> 'should_not_get_this

The problem is that COLDC_FUNC(set_method_access) in ops/object.c will call cthrow() twice if you supply both a bad method name and a bad access type.  I'd assume a fix would be as simple as replacing the cthrow()s with THROW()s, although somebody who's more familiar with Genesis should verify this as I'm not sure why the non-returning cthrow() is ever used in the first place.