changed ip/port to 'struct sockaddr_in' in network form