Consistently use "superuser" instead of "super user"
[pgsql.git] / src / port / link.c
blob0b61da5a065559beee7fb8a09a10d1a9c2948c0b
1 /*-------------------------------------------------------------------------
3 * link.c
5 * Portions Copyright (c) 1996-2021, PostgreSQL Global Development Group
6 * Portions Copyright (c) 1994, Regents of the University of California
9 * IDENTIFICATION
10 * src/port/link.c
12 *-------------------------------------------------------------------------
15 #include "c.h"
17 #ifdef WIN32
19 int
20 link(const char *src, const char *dst)
23 * CreateHardLinkA returns zero for failure
24 * https://docs.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-createhardlinka
26 if (CreateHardLinkA(dst, src, NULL) == 0)
28 _dosmaperr(GetLastError());
29 return -1;
31 else
32 return 0;
35 #endif