MFC r279326:

Use pthread_mutex_trylock(3) to implement mtx_trylock(3).
This commit is contained in:
kib 2015-03-05 09:01:46 +00:00
parent e4e2464970
commit 5458a77d46

View File

@ -96,7 +96,7 @@ int
mtx_trylock(mtx_t *mtx)
{
switch (pthread_mutex_lock(mtx)) {
switch (pthread_mutex_trylock(mtx)) {
case 0:
return (thrd_success);
case EBUSY: