def bound_socket(*args, **kwargs):
 sock = SOCKET_SOCKET(*args, **kwargs)
 sock.bind((SOURCE, 0))
 return sock

def bound_socket ( * args , ** kwargs ) : sock = SOCKET_SOCKET ( * args , ** kwargs ) sock . bind ( ( SOURCE , 0 ) ) return sock
bind socket to a specified source ip address .