Numerous fixes and one commented out bug.
What was I thinking, of course those locks aren't redundant...