http://www.perlmonks.org?node_id=560151


in reply to Re^4: perlembed: mortalize an AV, get "Attempt to free unreferenced scalar" - don't mortalize, leaks memory
in thread perlembed: mortalize an AV, get "Attempt to free unreferenced scalar" - don't mortalize, leaks memory

Amended accordingly (studying the version you cite av_clear appears to have been renamed to Perl_av_clear and the new av_clear has another purpose).

-M

Free your mind

  • Comment on Re^5: perlembed: mortalize an AV, get "Attempt to free unreferenced scalar" - don't mortalize, leaks memory

Replies are listed 'Best First'.
Re^6: perlembed: mortalize an AV, get "Attempt to free unreferenced scalar" - don't mortalize, leaks memory
by gellyfish (Monsignor) on Jul 10, 2006 at 15:05 UTC

    Er, in the perl API all the public functions are defined as Perl_<whatever> and documented without the Perl_ prefix, they are also available without the prefix through macros defined in embed.h. This was the case equally for the 5.6 MacPerl source that you originally looked at. I pointed you at the APC repository not because there was any particular difference in that function (except for some tidying and type changes they are largely identical between the two versions,) but simply because the MacPerl source you pointed to is more than four years old and based on the 5.6 source, whereas the APC reflects the current versions of Perl.

    /J\

    A reply falls below the community's threshold of quality. You may see it by logging in.