fix client -> server read/write bugs. close frames working now