From: Victor Shepelev Date: 2006-03-27T00:04:51+09:00 Subject: Re: Saving Proc object in C extension > >>>>> "V" == Victor Shepelev writes: > > V> static VALUE save_callback(VALUE self, VALUE proc) > V> { > V> ...bla-bla-bla... > > V> rb_global_variable(&proc); //as recommended in "Extending Ruby" > > proc is on the stack, after the end of save_callback() &proc don't make > reference to the proc object. > > V> What I do wrong? > > This is g_callback which must be registered. Thanks Guy! I've expected rb_global_variable uses only value of proc, not address. Now I've understand my error. Thanks! > Guy Decoux Victor.