bugfix for server connecting to port