Add missing FreeDir in CheckTablespaceDirectory

Started by Chao Liabout 2 months ago4 messageshackers
Jump to latest
#1Chao Li
li.evan.chao@gmail.com

Hi,

While reviewing another patch, I spotted that CheckTablespaceDirectory() in xlogrecovery.c misses to call FreeDir() after AllocateDir(). This seems to be an oversight in 9e4f914b5eba, where CheckTablespaceDirectory() was introduced.

Then I searched the source tree and didn’t find any other occurrences. Attached is a quick fix that adds the missing FreeDir().

Best regards,
--
Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/

Attachments:

t254134_1
v1-0001-Add-missing-FreeDir-in-CheckTablespaceDirectory.patchapplication/octet-stream; name=v1-0001-Add-missing-FreeDir-in-CheckTablespaceDirectory.patch; x-unix-mode=0644Download+1-1
#2Fujii Masao
masao.fujii@gmail.com
In reply to: Chao Li (#1)
Re: Add missing FreeDir in CheckTablespaceDirectory

On Sat, Oct 10, 2026 at 6:09 PM Chao Li <li.evan.chao@gmail.com> wrote:

Hi,

While reviewing another patch, I spotted that CheckTablespaceDirectory() in xlogrecovery.c misses to call FreeDir() after AllocateDir(). This seems to be an oversight in 9e4f914b5eba, where CheckTablespaceDirectory() was introduced.

Thanks for the patch! LGTM. I'll apply it next week.

Regards,

--
Fujii Masao

#3Fujii Masao
masao.fujii@gmail.com
In reply to: Fujii Masao (#2)
Re: Add missing FreeDir in CheckTablespaceDirectory

On Sun, Oct 11, 2026 at 1:05 AM Fujii Masao <masao.fujii@gmail.com> wrote:

Thanks for the patch! LGTM. I'll apply it next week.

I've pushed the patch. Thanks!

Regards,

--
Fujii Masao

#4Chao Li
li.evan.chao@gmail.com
In reply to: Fujii Masao (#3)
Re: Add missing FreeDir in CheckTablespaceDirectory

On Oct 14, 2026, at 10:17, Fujii Masao <masao.fujii@gmail.com> wrote:

On Sun, Oct 11, 2026 at 1:05 AM Fujii Masao <masao.fujii@gmail.com> wrote:

Thanks for the patch! LGTM. I'll apply it next week.

I've pushed the patch. Thanks!

Regards,

--
Fujii Masao

Thanks a lot for pushing.

Best regards,
--
Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/