在 2024-03-06 17:09, Martin Storsjö 写道:
From: Mateusz Mikuła
(...)
The changes in this patch were proposed by Josh Stone on Rust's Zulip
server and I was asked to forward it.
Co-Authored-By: Josh Stone
Signed-off-by: Mateusz Mikuła
Signed-off-by: Martin Storsjö
---
mingw-w64-crt/misc/mkste
Dnia środa, 6 marzec 2024 10:09:30 (+01:00), Martin Storsjö napisał(a):
> On Mon, 4 Mar 2024, Martin Storsjö wrote:
>
> > Looking closer at our mkstemp implementation, we have this loop:
> >
> >/*
> >Like OpenBSD, mkstemp() will try at least 2 ** 31 combinations before
> >giv
From: Mateusz Mikuła
When using mkstemp, there is no guarantee nor expectation that the
caller has called srand() with an unique seed. Therefore, in practice,
many users of mkstemp run with the same seed (unseeded).
Normally, the implementation of mkstemp does handle collisions just
fine, by con
On Mon, 4 Mar 2024, Martin Storsjö wrote:
Looking closer at our mkstemp implementation, we have this loop:
/*
Like OpenBSD, mkstemp() will try at least 2 ** 31 combinations before
giving up.
*/
for (i = 0; i >= 0; i++) {
for(j = index; j < len; j++) {
t