4 ms·
A function which sets global process state is not thread safe? Why, I'm shocked; shocked and chagrined. But really, I don't understand why a sensitive security
by einpoklum 2y ago
A function which sets global process state is not thread safe? Why, I'm shocked; shocked and chagrined.
But really, I don't understand why a sensitive security-related library would implicitly use an unsafe function like setenv().
- bangaladore 2y ago> A function which sets global process state is not thread safe? Why, I'm shocked; shocked and chagrined. This is a oversimplification. Windows has essentially the exact same API and it works just fine in multithreaded contexts. The issue here is unix allows the underlying pointer to be accessed, bypassing any possible thread-safe APIs.