X-Git-Url: http://nsz.repo.hu/git/?p=musl;a=blobdiff_plain;f=src%2Fthread%2Fpthread_create.c;h=1e55a6f944a26987f783a5cdef19454655b02c7b;hp=4c1decaa7ce5f660ace954a032fcd88751e603d6;hb=077549e0d468ff47fdf3e00bb3cfdb929ac8324f;hpb=d5142642b8e6c45449158efdb8f8e87af4dafde8 diff --git a/src/thread/pthread_create.c b/src/thread/pthread_create.c index 4c1decaa..1e55a6f9 100644 --- a/src/thread/pthread_create.c +++ b/src/thread/pthread_create.c @@ -188,7 +188,7 @@ int pthread_create(pthread_t *restrict res, const pthread_attr_t *restrict attrp if (ret < 0) { a_dec(&libc.threads_minus_1); - munmap(map, size); + if (map) munmap(map, size); return EAGAIN; }