Added a bit of TCP support.