From 64f30bb206f41b1d94d108466e259c1c9c9c2b73 Mon Sep 17 00:00:00 2001 From: Andrew Dunstan Date: Fri, 29 Feb 2008 23:31:20 +0000 Subject: [PATCH] Don't call AddUserToDacl on Cygwin --- src/bin/initdb/initdb.c | 4 +++- src/bin/pg_ctl/pg_ctl.c | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c index 41db8a8b02..193318d5f9 100644 --- a/src/bin/initdb/initdb.c +++ b/src/bin/initdb/initdb.c @@ -42,7 +42,7 @@ * Portions Copyright (c) 1994, Regents of the University of California * Portions taken from FreeBSD. * - * $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.154 2008/02/29 15:31:33 mha Exp $ + * $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.155 2008/02/29 23:31:20 adunstan Exp $ * *------------------------------------------------------------------------- */ @@ -2346,7 +2346,9 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION * processInfo) return 0; } +#ifndef __CYGWIN__ AddUserToDacl(processInfo->hProcess); +#endif return ResumeThread(processInfo->hThread); } diff --git a/src/bin/pg_ctl/pg_ctl.c b/src/bin/pg_ctl/pg_ctl.c index 9e0e16ca6b..89fc34d686 100644 --- a/src/bin/pg_ctl/pg_ctl.c +++ b/src/bin/pg_ctl/pg_ctl.c @@ -4,7 +4,7 @@ * * Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group * - * $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.95 2008/02/29 15:31:33 mha Exp $ + * $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.96 2008/02/29 23:31:20 adunstan Exp $ * *------------------------------------------------------------------------- */ @@ -1469,7 +1469,9 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION * processInfo) } } +#ifndef __CYGWIN__ AddUserToDacl(processInfo->hProcess); +#endif CloseHandle(restrictedToken);