Fixup handling of pthread_mutex*() error returns