components/libpcap/patches/02-pcap-bpf-any.patch
branchs11u3-sru
changeset 6387 77663b44ddf4
equal deleted inserted replaced
6383:b75d30310eac 6387:77663b44ddf4
       
     1 Adding the "any" pseudo-device since Solaris supports it.
       
     2 This is an in-house patch and will eventually be sent upstream.
       
     3 
       
     4 --- libpcap-1.5.1/pcap-bpf.c	Fri Jun 17 13:21:04 2016
       
     5 +++ new/pcap-bpf.c	Fri Jun 17 13:20:50 2016
       
     6 @@ -2305,6 +2305,17 @@
       
     7  int
       
     8  pcap_platform_finddevs(pcap_if_t **alldevsp, char *errbuf)
       
     9  {
       
    10 +
       
    11 +#ifdef DLT_IPNET
       
    12 +	/*
       
    13 +	 * Adding the "any" pseudo-device
       
    14 +	 */
       
    15 +	const char any_descr[] = "Pseudo-device that captures on all interfaces";
       
    16 +	if (pcap_add_if(alldevsp, "any", IFF_UP|IFF_RUNNING,
       
    17 +	    any_descr, errbuf) < 0)
       
    18 +		return (-1);
       
    19 +#endif
       
    20 +
       
    21  	return (0);
       
    22  }
       
    23