Fix OS.connect, and implement read(), write() & send() on CompatTCPSocketClass

These are needed for `Open.socket` to work correctly.

(I haven't tried `recv`, so I didn't implement it.)