diff options
author | Guy Harris <guy@alum.mit.edu> | 2018-11-20 10:33:07 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2018-11-20 10:33:07 -0800 |
commit | 8b40ffd344971073013aabe3c9c4a2db47ca7b43 (patch) | |
tree | cd1709a569f6cb9a87490a39951b6808719801d5 /pcap-snf.c | |
parent | cf7c3f5b17a33cff1e9ffd9b17377f857d017c7f (diff) | |
download | libpcap-8b40ffd344971073013aabe3c9c4a2db47ca7b43.tar.gz |
Count only packets that were handed to the callback.
That's how other devices work.
Diffstat (limited to 'pcap-snf.c')
-rw-r--r-- | pcap-snf.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -182,8 +182,8 @@ snf_read(pcap_t *p, int cnt, pcap_handler callback, u_char *user) hdr.caplen = caplen; hdr.len = req.length; callback(user, &hdr, req.pkt_addr); + n++; } - n++; /* After one successful packet is received, we won't block * again for that timeout. */ |