Fix a bunch of bugs, lock-free is sooooo hard....