merged connect() and receive()
parsing quit and replys