Use scoped lock inside mac-specific XrdSysSemaphore implementation to avoid deadlock on thread cancellation

If a thread is waiting inside XrdSysCondVar::Wait and the thread is cancelled, the mutex is not released, therefore causing deadlock when other threads attempt to lock it.

The simple fix is to use a scoped lock to ensure the mutex is unlocked in the destructor if the thread is cancelled.