Make unlink() work for junction points on Windows.
authorThomas Munro <tmunro@postgresql.org>
Sat, 6 Aug 2022 00:01:42 +0000 (12:01 +1200)
committerThomas Munro <tmunro@postgresql.org>
Sat, 6 Aug 2022 00:50:59 +0000 (12:50 +1200)
commitf357233c9db8be2a015163da8e1ab0630f444340
treebeac64515f530907a6e4f1c7520e56ed51034632
parentc5cb8f3b770c043509b61528664bcd805e1777e6
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
src/port/dirmod.c