/* Not all interfaces are DLPI interfaces, and thus not all interfaces can be opened with DLPI (for example, the loopback interface is not a DLPI interface on Solaris prior to Solaris 11), so try to open the specified interface; return 0 if we fail with PCAP_ERROR_NO_SUCH_DEVICE and 1 otherwise.  */
static int is_dlpi_interface(const char *name)
/* Not all interfaces are DLPI interfaces, and thus not all interfaces can be opened with DLPI (for example, the loopback interface is not a DLPI interface on Solaris prior to Solaris 11), so try to open the specified interface; return 0 if we fail with PCAP_ERROR_NO_SUCH_DEVICE and 1 otherwise.  */
static int is_dlpi_interface(const char *name)
{
	int fd;
	u_int ppa;
	char errbuf[PCAP_ERRBUF_SIZE];
	fd = open_dlpi_device(name, &ppa, errbuf);
	if (fd < 0) {
		if (fd == PCAP_ERROR_NO_SUCH_DEVICE) {
			return (0);
		}
		return (1);
	}
	close(fd);
	return (1);
}