Bug fix to tryLock and lock exclusivity.