From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Nathan Bossart <nathandbossart(at)gmail(dot)com> |
Cc: | Daniel Gustafsson <daniel(at)yesql(dot)se>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Andrew Dunstan <andrew(at)dunslane(dot)net> |
Subject: | Re: Setting restrictedtoken in pg_regress |
Date: | 2023-06-12 23:29:19 |
Message-ID: | ZIeqT46aBwmwThrP@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Jun 12, 2023 at 04:12:22PM -0700, Nathan Bossart wrote:
> On Tue, Aug 30, 2022 at 03:02:54PM +0200, Daniel Gustafsson wrote:
>> In pg_regress we set restrictedToken when calling CreateRestrictedProcess, but
>> we never seem to use that anywhere. Not being well versed in Windows I might
>> be missing something, but is it needed or is it a copy/pasteo from fa1e5afa8a2
>> which does that in restricted_token.c? If not needed, removing it makes the
>> code more readable IMO.
>
> Looks reasonable to me.
Indeed, looks like a copy-pasto to me.
I am actually a bit confused with the return value of
CreateRestrictedProcess() on failures in restricted_token.c. Wouldn't
it be cleaner to return INVALID_HANDLE_VALUE rather than 0 in these
cases?
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Nathan Bossart | 2023-06-12 23:30:15 | Re: [PATCH] Slight improvement of worker_spi.c example |
Previous Message | Stephen Frost | 2023-06-12 23:24:18 | Re: Atomic ops for unlogged LSN |