Locks the specified reader-writer lock for writing.
#include <pthread.h> int pthread_rwlock_timedwrdlock ( pthread_rwlock_t *rwlock, const struct timespec *abs_timeout);
(IN) Points to reader-writer lock that you want to lock for writing.
(IN) Points to a timespec structure which specifies the maximum amount of time you are willing to wait. See timespec_t, which is also called timespec and timestrc_t.
If successful, returns zero; otherwise, returns a nonzero error code:
If the lock is immediately available, the pthread_rwlock_timedwrlock function acquires the lock and returns. If the lock is not immediately available, the calling thread blocks and waits the specified time. If the lock becomes available during this time, the pthread_rwlock_timedwrlock function acquires the lock and returns. If it doesn't become available during this time, the function sets errno to ETIMEDOUT.