def send(self, data, dst=None):
    '\n        Send data to a specified destination.\n\n        :param bytes data: Data to send.\n        :param tuple dst:\n            Tuple of (`str`, `int`) describing the destination address and port,\n            respectively.\n        '
    try:
        ret = self.sock.sendto(data, dst)
    except OSError as e:
        errno = e.args[0]
        logging.error('Error sending %dB to %s: %s', len(data), dst, e)
        if (errno == ENETUNREACH):
            raise SCMPUnreachNet(dst)
        elif (errno == EHOSTUNREACH):
            raise SCMPUnreachHost(dst)
        return False
    if (ret != len(data)):
        logging.error('Wanted to send %dB, only sent %dB', len(data), ret)
        return False
    return True
Send data to a specified destination.

:param bytes data: Data to send.
:param tuple dst:
    Tuple of (`str`, `int`) describing the destination address and port,
    respectively.
def send(self, data, dst=None):
    '\n        Send data to a specified destination.\n\n        :param bytes data: Data to send.\n        :param tuple dst:\n            Tuple of (`str`, `int`) describing the destination address and port,\n            respectively.\n        '
    try:
        ret = self.sock.sendto(data, dst)
    except OSError as e:
        errno = e.args[0]
        logging.error('Error sending %dB to %s: %s', len(data), dst, e)
        if (errno == ENETUNREACH):
            raise SCMPUnreachNet(dst)
        elif (errno == EHOSTUNREACH):
            raise SCMPUnreachHost(dst)
        return False
    if (ret != len(data)):
        logging.error('Wanted to send %dB, only sent %dB', len(data), ret)
        return False
    return True