From: | Ranier Vilela <ranier(dot)vf(at)gmail(dot)com> |
---|---|
To: | Daniel Gustafsson <daniel(at)yesql(dot)se> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Fix resource leak (src/backend/libpq/be-secure-common.c) |
Date: | 2024-04-10 18:31:02 |
Message-ID: | CAEudQArcwFzYdGcRk8Tyf2ij0DR7mOoqSJejsa00+SkTjFNHSw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Em ter., 2 de abr. de 2024 às 15:31, Daniel Gustafsson <daniel(at)yesql(dot)se>
escreveu:
> > On 2 Apr 2024, at 20:13, Ranier Vilela <ranier(dot)vf(at)gmail(dot)com> wrote:
>
> > Fix by freeing the pointer, like pclose_check (src/common/exec.c)
> similar case.
>
> Off the cuff, seems reasonable when loglevel is LOG.
>
Per Coverity.
Another case of resource leak, when loglevel is LOG.
In the function shell_archive_file (src/backend/archive/shell_archive.c)
The pointer *xlogarchcmd* is not freed.
best regards,
Ranier Vilela
Attachment | Content-Type | Size |
---|---|---|
fix-resource-leak-shell_archive.patch | application/octet-stream | 525 bytes |
From | Date | Subject | |
---|---|---|---|
Next Message | Jelte Fennema-Nio | 2024-04-10 18:31:57 | Re: psql: Greatly speed up "\d tablename" when not using regexes |
Previous Message | Kirill Reshke | 2024-04-10 18:20:48 | Re: psql: Greatly speed up "\d tablename" when not using regexes |