Fix bug in blockLock