X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fthread%2Fpthread_rwlock_init.c;h=a2c0b478c78cf36ef7f15e4d65956e517c647221;hb=bf14ef193b4203aa9a8b173faeeea06d98397f65;hp=29003bc651493d551eabef97f68fbf795101debf;hpb=400c5e5c8307a2ebe44ef1f203f5a15669f20347;p=musl diff --git a/src/thread/pthread_rwlock_init.c b/src/thread/pthread_rwlock_init.c index 29003bc6..a2c0b478 100644 --- a/src/thread/pthread_rwlock_init.c +++ b/src/thread/pthread_rwlock_init.c @@ -2,8 +2,7 @@ int pthread_rwlock_init(pthread_rwlock_t *restrict rw, const pthread_rwlockattr_t *restrict a) { - memset(rw, 0, sizeof *rw); - if (a) { - } + *rw = (pthread_rwlock_t){0}; + if (a) rw->_rw_shared = a->__attr[0]*128; return 0; }