fako1024/slimcap

Mock packet stats / counter not atomic

Closed this issue · 0 comments

Issue els0r/goProbe#117 revealed that the mock packet counter has a race condition when accessing mock source packet stats while still processing. This should be easily fixable by making the counter atomic.

DoD

  • Reproduce via race detector
  • Make MockFileDescriptor packet counter atomic
  • Extend testing to cover scenario via race detector