Add some asserts, fix some not-quite-bugs.
1 file changed