diff --git a/libnetutil/netutil.cc b/libnetutil/netutil.cc index c7dfa5be8..31de2aff4 100644 --- a/libnetutil/netutil.cc +++ b/libnetutil/netutil.cc @@ -4153,7 +4153,11 @@ pcap_t *my_pcap_open_live(const char *device, int snaplen, int promisc, int to_m /* This is unnecessary with Npcap since libpcap calls PacketSetMinToCopy(0) * based on immediate mode. Have not determined if it is needed for WinPcap * or not, but it's not hurting anything. */ - pcap_setmintocopy(pt, 1); + pcap_setmintocopy(pt, 0); + /* Npcap sets kernel buffer size to 1MB, but user buffer size to 256KB. + * Memory is pretty cheap these days, so lets match the kernel buffer size + * for better performance. */ + pcap_setuserbuffer(pt, 1000000); #endif return pt;