I came across this piece of MingW source code:
94 /* In some embedded systems, this does not get
set. This protects
95 newlib from dereferencing a bad pointer. */
96 if (!*p_environ)
97 return NULL;
It immediately stroke me as a place were a lock may not
be released. The other places in the code look fine:
116 return NULL;
I simply suggest to move ENV_LOCK after the *p_environ
early exit test.
Log in to post a comment.