2013年12月5日 - The second argument to getsockname should be a struct sockaddr * . You're passing the address of a struct sockaddr_in .
stackoverflow.com