in reply to Memory leak dealing with AVs

You undef av, but don't free it. Try replacing av_undef(av) with SvREFCNT_dec(av)

Dave.

Replies are listed 'Best First'.
Re^2: Memory leak dealing with AVs
by polettix (Vicar) on Sep 23, 2006 at 09:18 UTC
    It helps, but the problem seems to remain:
    ROUND SvREFCNT_dec av_undef 100 5524 5528 200 5528 5536 300 5532 5544 400 5540 5816 500 5544 5824 600 5548 5832 700 5552 5840 800 5556 5848 900 5560 5860 1000 5564 5868

    Flavio
    perl -ple'$_=reverse' <<<ti.xittelop@oivalf

    Don't fool yourself.
      The remaining leak is caused by your instrumentation. Try adding fclose(fh)

      Dave.

        /me joyful
        100 5524 200 5524 300 5524 400 5524 500 5524 600 5524 700 5524 800 5524 900 5524 1000 5524

        You're absolutely right. This is where Perl has really spoiled me - using lexical, auto-closing filehandles is sooooo handy!

        Flavio
        perl -ple'$_=reverse' <<<ti.xittelop@oivalf

        Don't fool yourself.