Re: [PATCH] Fix Potential Memory Leak in pg_amcheck Code

2025-02-23 Thread Daniel Gustafsson
> On 23 Feb 2025, at 13:03, Jelte Fennema-Nio wrote: > > On Sun, 23 Feb 2025 at 07:49, Kirill Reshke wrote: >> So, are we +1 or -1 on moving this forward? > > +1 from me. Marked as ready for committer. Agreed, I have it on my TODO for the week to revisit. ./daniel

Re: [PATCH] Fix Potential Memory Leak in pg_amcheck Code

2025-02-23 Thread Jelte Fennema-Nio
On Sun, 23 Feb 2025 at 07:49, Kirill Reshke wrote: > So, are we +1 or -1 on moving this forward? +1 from me. Marked as ready for committer.

Re: [PATCH] Fix Potential Memory Leak in pg_amcheck Code

2025-02-22 Thread Kirill Reshke
Hi! On Fri, 7 Feb 2025 at 13:28, Daniel Gustafsson wrote: > > That being said, there is > value in doing the right thing and setting good examples in our own code as > many do read it and reference it. > We call PQclear on such a > case elsewhere in the file so it's not entirely consistent, but

Re: [PATCH] Fix Potential Memory Leak in pg_amcheck Code

2025-02-07 Thread Daniel Gustafsson
> On 7 Feb 2025, at 08:04, Saladin <312199...@qq.com> wrote: > > Dear pgsql-hackers, > > While reviewing the code of pg_amcheck, I discovered a potential issue that > could lead to a memory leak. Specifically, there is a missing PQclear(result) > call before the database connection is disconnec

[PATCH] Fix Potential Memory Leak in pg_amcheck Code

2025-02-06 Thread Saladin
Dear pgsql-hackers, While reviewing the code of pg_amcheck, I discovered a potential issue that could lead to a memory leak. Specifically, there is a missing PQclear(result) call before the database connection is disconnected, which could leave the query result unfreed. To resolve this,