More lock consistency fixes.