Make unlink() work for junction points on Windows.

Thomas Munro <tmunro@postgresql.org>

Commit: f357233c9db8be2a015163da8e1ab0630f444340
Author: Thomas Munro <tmunro@postgresql.org>
Date: 2022-08-06T00:50:59Z
Releases: 16.0
Make unlink() work for junction points on Windows.

To support harmonization of Windows and Unix code, teach our unlink()
wrapper that junction points need to be unlinked with rmdir() on
Windows.

Tested-by: Andrew Dunstan <andrew@dunslane.net>
Discussion: https://postgr.es/m/CA%2BhUKGLfOOeyZpm5ByVcAt7x5Pn-%3DxGRNCvgiUPVVzjFLtnY0w%40mail.gmail.com

Files

PathChange+/−
src/port/dirmod.c modified +27 −1

Discussion