Re: Having memory leak issues with perl-c

2022-08-12 Thread Mark Murawski
On 8/12/22 18:26, Mark Murawski wrote: On 8/12/22 18:11, Mark Murawski wrote: On 8/4/22 15:10, demerphq wrote: On Thu, 4 Aug 2022 at 17:04, Mark Murawski wrote: On 8/4/22 02:50, demerphq wrote: On Thu, 4 Aug 2022 at 01:58, Mark Murawski wrote: I'm still not getting som

Re: Having memory leak issues with perl-c

2022-08-12 Thread Mark Murawski
On 8/12/22 18:11, Mark Murawski wrote: On 8/4/22 15:10, demerphq wrote: On Thu, 4 Aug 2022 at 17:04, Mark Murawski wrote: On 8/4/22 02:50, demerphq wrote: On Thu, 4 Aug 2022 at 01:58, Mark Murawski wrote: I'm still not getting something... if I want to fix the c

Re: Having memory leak issues with perl-c

2022-08-12 Thread Mark Murawski
On 8/4/22 15:10, demerphq wrote: On Thu, 4 Aug 2022 at 17:04, Mark Murawski wrote: On 8/4/22 02:50, demerphq wrote: On Thu, 4 Aug 2022 at 01:58, Mark Murawski wrote: I'm still not getting something... if I want to fix the code-as-is and do this:     FNsv

Re: Having memory leak issues with perl-c

2022-08-04 Thread demerphq
On Thu, 4 Aug 2022 at 17:04, Mark Murawski wrote: > On 8/4/22 02:50, demerphq wrote: > > On Thu, 4 Aug 2022 at 01:58, Mark Murawski > wrote: > >> I'm still not getting something... if I want to fix the code-as-is and do >> this: >> >> FNsv = get_sv("main::_FN", GV_ADD); >> if (!FNsv) >>

Re: Having memory leak issues with perl-c

2022-08-04 Thread Mark Murawski
On 8/4/22 02:50, demerphq wrote: On Thu, 4 Aug 2022 at 01:58, Mark Murawski wrote: I'm still not getting something... if I want to fix the code-as-is and do this:     FNsv = get_sv("main::_FN", GV_ADD);     if (!FNsv)     ereport(ERROR, (errcode(ERRCODE_EXTERNAL_RO

Re: Having memory leak issues with perl-c

2022-08-03 Thread demerphq
On Thu, 4 Aug 2022 at 01:58, Mark Murawski wrote: > I'm still not getting something... if I want to fix the code-as-is and do > this: > > FNsv = get_sv("main::_FN", GV_ADD); > if (!FNsv) > ereport(ERROR, > (errcode(ERRCODE_EXTERNAL_ROUTINE_EXCEPTION), >

Re: Having memory leak issues with perl-c

2022-08-03 Thread Mark Murawski
On 7/27/22 13:20, demerphq wrote: A general rule of thumb however is that any item you create yourself which is not "owned by perl" by being attached to some data structure it exposes is your problem to deal with. So for instance this:      FNsv = get_sv("main::_FN", GV_ADD); is getting you

Re: Having memory leak issues with perl-c

2022-07-28 Thread demerphq
On Thu, 28 Jul 2022 at 10:35, demerphq wrote: > On Wed, 27 Jul 2022 at 22:41, Mark Murawski > wrote: > >> >> >> On 7/27/22 13:20, demerphq wrote: >> >> Spectacular. I'll be reviewing and making changes that you're suggesting >> and this helps my understanding for sure. >> > > I was a bit off my

Re: Having memory leak issues with perl-c

2022-07-28 Thread demerphq
On Wed, 27 Jul 2022 at 22:41, Mark Murawski wrote: > > > On 7/27/22 13:20, demerphq wrote: > > Spectacular. I'll be reviewing and making changes that you're suggesting > and this helps my understanding for sure. > I was a bit off my game yesterday. I should have told you to make liberal use of

Re: Having memory leak issues with perl-c

2022-07-27 Thread Mark Murawski
On 7/27/22 13:20, demerphq wrote: On Wed, 27 Jul 2022 at 17:46, Mark Murawski wrote: Hi All! I'm working on a new feature for plperl in postgresql to populate some metadata in main::_FN for running plperl functions from postgres sql. I've snipped out some extra code tha

Re: Having memory leak issues with perl-c

2022-07-27 Thread demerphq
On Wed, 27 Jul 2022 at 17:46, Mark Murawski wrote: > Hi All! > > I'm working on a new feature for plperl in postgresql to populate some > metadata in main::_FN for running plperl functions from postgres sql. > > I've snipped out some extra code that's unrelated to focus on the issue > at hand.