/* Set interface as duplicate if another is found on the same subnet.  */
static void _mdns_dup_interface(tcpip_adapter_if_t tcpip_if)
/* Set interface as duplicate if another is found on the same subnet.  */
static void _mdns_dup_interface(tcpip_adapter_if_t tcpip_if)
{
    uint8_t i;
    tcpip_adapter_if_t other_if = _mdns_get_other_if (tcpip_if);
    for (i=0; i<MDNS_IP_PROTOCOL_MAX; i++) {
        if (_mdns_server->interfaces[other_if].pcbs[i].pcb) {
            if (_mdns_server->interfaces[tcpip_if].pcbs[i].pcb) {
                _mdns_clear_pcb_tx_queue_head(tcpip_if, i);
                _mdns_pcb_deinit(tcpip_if, i);
            }
            _mdns_server->interfaces[tcpip_if].pcbs[i].state = PCB_DUP;
            _mdns_announce_pcb(other_if, i, NULL, 0, true);
        }
    }
}