flow-manager: only update FlowBucket::next_ts if it changed

pull/5279/head
Victor Julien 5 years ago
parent 1d6d7f0858
commit 6814f08e93

@ -483,7 +483,9 @@ static uint32_t FlowTimeoutHash(struct timeval *ts, uint32_t try_cnt,
/* we have a flow, or more than one */
cnt += FlowManagerHashRowTimeout(fb->tail, ts, emergency, counters, &next_ts);
SC_ATOMIC_SET(fb->next_ts, next_ts);
if (SC_ATOMIC_GET(fb->next_ts) != next_ts) {
SC_ATOMIC_SET(fb->next_ts, next_ts);
}
next:
FBLOCK_UNLOCK(fb);

Loading…
Cancel
Save