added connection setup to client

performs socket() and connect() operations