it's said libpcap will yield IP packets directly, without encapsulating PPP packets, when sniffing a PPP interface.

blindly adding handling code for that...
This commit is contained in:
Arnout Engelen
2006-11-04 16:59:44 +00:00
parent 4a866021fc
commit 7fbbe70e0c
3 changed files with 11 additions and 0 deletions

View File

@@ -209,6 +209,10 @@ void dp_pcap_callback (u_char * u_handle, const struct pcap_pkthdr * header, con
case (DLT_PPP):
dp_parse_ppp (handle, header, packet);
break;
case (DLT_RAW):
case (DLT_NULL):
// just a guess
dp_parse_ip (handle, header, packet);
default:
// TODO maybe error? or 'other' callback?
break;