After exiting the try-again loop, make one more test of the lock
conditions, in case it was released while a signal handler kept the
thread busy past the alarm expiration.
- return EPERM when unlocking a lock which isn't held
=> prevent the failure in PR 24023, where the citrus code had a deadlocking
code path
- remove deadlock check in pthread_rwlock_tryrdlock, return EBUSY instead
=> makes pthread_rwlock_tryrdlock standards compliant