Allow NULL in pthread_mutex_lock/unlock.
The pthread_mutex_lock and pthread_mutex_unlock were allowed to
fail silently on L 32 bit devices when passed a NULL. We changed
this to a crash on 32 bit devices, but there are still games that make
these calls and are not likely to be updated. Therefore, once again
allow NULL to be passed in on 32 bit devices.
Bug: 19995172
(cherry picked from commit 511cfd9dc8)
Change-Id: I159a99a941cff94297ef3fffda7075f8ef1ae252
This commit is contained in:
@@ -176,10 +176,18 @@ int pthread_mutexattr_settype(pthread_mutexattr_t*, int) __nonnull((1));
|
||||
|
||||
int pthread_mutex_destroy(pthread_mutex_t*) __nonnull((1));
|
||||
int pthread_mutex_init(pthread_mutex_t*, const pthread_mutexattr_t*) __nonnull((1));
|
||||
#if !defined(__LP64__)
|
||||
int pthread_mutex_lock(pthread_mutex_t*) /* __nonnull((1)) */;
|
||||
#else
|
||||
int pthread_mutex_lock(pthread_mutex_t*) __nonnull((1));
|
||||
#endif
|
||||
int pthread_mutex_timedlock(pthread_mutex_t*, const struct timespec*) __nonnull((1, 2));
|
||||
int pthread_mutex_trylock(pthread_mutex_t*) __nonnull((1));
|
||||
#if !defined(__LP4__)
|
||||
int pthread_mutex_unlock(pthread_mutex_t*) /* __nonnull((1)) */;
|
||||
#else
|
||||
int pthread_mutex_unlock(pthread_mutex_t*) __nonnull((1));
|
||||
#endif
|
||||
|
||||
int pthread_once(pthread_once_t*, void (*)(void)) __nonnull((1, 2));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user