af-packet: fix emergency mode

This patch fixes emergency mode by setting the variable even if we
have a non kernel checksum check. It also does a call to
AFPDUmpCounters() as it seems to improve thing to do it ASAP.
pull/57/merge
Eric Leblond 13 years ago committed by Victor Julien
parent 6040016347
commit ee6ba09948

@ -755,9 +755,10 @@ int AFPReadFromRing(AFPThreadVars *ptv)
if (h.h2->tp_status & TP_STATUS_CSUMNOTREADY) {
p->flags |= PKT_IGNORE_CHECKSUM;
}
if (h.h2->tp_status & TP_STATUS_LOSING) {
emergency_flush = 1;
}
}
if (h.h2->tp_status & TP_STATUS_LOSING) {
emergency_flush = 1;
AFPDumpCounters(ptv, 1);
}
if (TmThreadsSlotProcessPkt(ptv->tv, ptv->slot, p) != TM_ECODE_OK) {

Loading…
Cancel
Save