Re: [PATCH] wrapper: simplify xmkstemp()
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Nov 20, 2025, 14:39 UTC
- Message-ID
- <xmqqbjkwahu1.fsf@gitster.g>
- In-Reply-To
- <20251120082328.GD1283645@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 6 quoted lines
>> > +#define mkstemp(template) git_mkstemp_mode((template), 0600) > > So this patch implements what I was thinking, though I probably would > have made it more explicit: add mkstemp() to the banned list (not > because it's evil but because it's unportable) and force callers to use > git_mkstemp_mode() explicitly.
Because only a very small number (one?) of callers call mkstemp() in the current code, the above is probably a good thing to do.