many little changes to fix things, but there's still an important bug to fix: nothing is being returned on the CLOSE# command from the server