in reply to Re: Memory leak issue with Embedded Perl
in thread Memory leak issue with Embedded Perl

Thanks I will take a look further into the  my function. The  use strict is also a good suggestion I will add that and see if it helps. This database subroutine only gets called once everytime we go through the process - would the memory still be hanging around even though we have effectively run the script and then terminated it? Or am I working under an incorrect assumption?.... Certainly wouldn't be the first time!!

Replies are listed 'Best First'.
Re**3: Memory leak issue with Embedded Perl
by belg4mit (Prior) on Jul 25, 2003 at 01:11 UTC
    If the process truly is exiting then yes, the memory will be freed. This isn't a daemon? And while this does not directly address the issue of leaking memory but a couple other observations.
    1. Your foreach loop seems to contain a useless assignment ($^W=1 would expose that).
    2. There must be a C library for handling DBM files, such as http://www.sleepycat.com

    --
    I'm not belgian but I play one on TV.

      It is a client process running constantly under Tuxedo, which invokes the script via the embedding code. I was under the impression that after it had run the script and exited using the code:
      PUTBACK; TMPS; LEAVE;
      would release the memory associated with perl.

      Anyway I have changed everything over to  use strict and my and the probelm is still occuring.

      I have now taken out the usless assignment - thanks for spotting that one... some old test code hanging around.

      Anything else I should be checking?

      Thanks