in reply to How to destroy embedded Perl interpreter cleanly (no memory leak)?

First off you should be calling perl_run so that your DESTROY methods and end blocks are executed at the right time. Have you looked at the simple demo of embedding that ships with Perl called miniperlmain.c?

I also think that it is a better idea to maintain a single interpreter rather than creating and destroying them all the time. I think this would help out with speed a lot since Perl would only have to be loaded into memory once.

cheers

JSchmitz
  • Comment on Re: How to destroy embedded Perl interpreter cleanly (no memory leak)?