Lines Matching refs:bpfSize
100 int bpfSize = 0; /* Number of unread bytes in buffer */
603 * bpfSize and bpfOffset variables to force a new read on the next
609 bpfSize = bpfOffset = 0;
632 if (bpfSize <= 0) {
634 if ((bpfSize = read(sock, bpfBuffer, bpfLength)) < 0) {
639 if (bpfSize < sizeof(hdr)) {
640 syslog(LOG_ERR, "Truncated bpf packet header: len=%d", bpfSize);
641 clearPacketHeader(pkt); /* resets bpfSize and bpfOffset */
648 clearPacketHeader(pkt); /* resets bpfSize and bpfOffset */
652 if (seglen > bpfSize) {
653 syslog(LOG_ERR, "Truncated bpf packet: seglen=%d, bpfSize=%d",
654 seglen, bpfSize);
655 clearPacketHeader(pkt); /* resets bpfSize and bpfOffset */
662 if (seglen >= bpfSize) {
663 bpfSize = bpfOffset = 0;
665 bpfSize -= seglen;