Trim out spaces and newlines in the address and port settings of the connection window.