util-ebpf: discard flow if no Flow storage

pull/3952/head
Eric Leblond 6 years ago committed by Victor Julien
parent dbf3606169
commit a8f35cc30e

@ -539,7 +539,8 @@ static int EBPFUpdateFlowForKey(struct flows_stats *flowstats, FlowKey *flow_key
FlowCounters *fc = FlowGetStorageById(f, GetFlowBypassCounterID()); FlowCounters *fc = FlowGetStorageById(f, GetFlowBypassCounterID());
if (fc == NULL) { if (fc == NULL) {
FLOWLOCK_UNLOCK(f); FLOWLOCK_UNLOCK(f);
return 0; flowstats->count++;
return pkts_cnt;
} }
if (flow_key->sp == f->sp) { if (flow_key->sp == f->sp) {
if (pkts_cnt != fc->todstpktcnt) { if (pkts_cnt != fc->todstpktcnt) {

Loading…
Cancel
Save