Compile-time fix and modifications to pass test-create and test-join
Adding a test for exit