check the length of dest_ports