From: Jan Bernhardt Date: 2003-05-15T06:47:12+09:00 Subject: Re: Embedding/GC/heap corruption problem On Wed, 14 May 2003 23:27:39 +0200, Simon Strandgaard wrote: > > void MessageEnd(void) { > rb_funcall(message_registry, rb_intern("dispatch_message"), 1, message); > RETURN_META(MRES_IGNORED); > } > > > > you don't wrap rb_funcall() within a rb_protect().. > Im guessing this is part of the reason. > > see - how to use rb_protect() warning: c++ > http://ruby-talk.org/71421 I used to do that, but during experimentation I removed the protection wrapper. But of course you're right - I should protect the function call. - Jan.