diff options
author | sam <sam@FreeBSD.org> | 2006-01-16 20:33:23 +0000 |
---|---|---|
committer | sam <sam@FreeBSD.org> | 2006-01-16 20:33:23 +0000 |
commit | bf281a32a1c59fe37a685431dd57d7e432a7f3e0 (patch) | |
tree | 232596edecd144ccc53c88fa90e72fe7ed4e0560 /contrib | |
parent | d1c1ca625af687a355eb6acd58948cd7ef9620be (diff) | |
download | FreeBSD-src-bf281a32a1c59fe37a685431dd57d7e432a7f3e0.zip FreeBSD-src-bf281a32a1c59fe37a685431dd57d7e432a7f3e0.tar.gz |
correct dlt buffer alloc; this goes on the vendor branch as it
will be committed there shortly
MFC after: 3 days
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/libpcap/pcap-bpf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/libpcap/pcap-bpf.c b/contrib/libpcap/pcap-bpf.c index ccf9d73..4a94cda 100644 --- a/contrib/libpcap/pcap-bpf.c +++ b/contrib/libpcap/pcap-bpf.c @@ -746,7 +746,7 @@ pcap_open_live(const char *device, int snaplen, int promisc, int to_ms, u_int i; int is_ethernet; - bdl.bfl_list = (u_int *) malloc(sizeof(u_int) * bdl.bfl_len + 1); + bdl.bfl_list = (u_int *) malloc(sizeof(u_int) * (bdl.bfl_len + 1)); if (bdl.bfl_list == NULL) { (void)snprintf(ebuf, PCAP_ERRBUF_SIZE, "malloc: %s", pcap_strerror(errno)); |