Ticket #116 (closed Problem: Duplicate)

Opened 3 years ago

Last modified 3 years ago

pcapo_stats symatics are now the same on linux and bsd

Reported by: jones@… Owned by:
Priority: Normal Milestone:
Component: Bro Version: branches-robin-work
Keywords: Cc:

Description

The following code in src/PktSrc.cc:

#ifdef HAVE_LINUX

Linux clears its counters each time.
s->received = stats.received;
s->dropped = stats.dropped + pstat.ps_drop;
s->link = 0;
not available

#else

Default assumes FreeBSD's semantics.
s->received = stats.received;
s->dropped = pstat.ps_drop;
s->link = pstat.ps_recv;

#endif

can be smplified to:

Default assumes FreeBSD's semantics.
s->received = stats.received;
s->dropped = pstat.ps_drop;
s->link = pstat.ps_recv;

With out this mode the error keep increasing on linux once you see a error.

Change History

comment:1 Changed 3 years ago by anonymous

Is there some #ifdef or autoconf goop we can use to retain backwards compatibility with older versions of Linux that still use the previous semantics?

comment:2 Changed 3 years ago by vern

Oops, for what it's worth, that last anonymous comment was from me

comment:3 Changed 3 years ago by robin

  • Status changed from new to closed
  • Resolution set to Duplicate

This is a duplicate of #18, please continue there.

Note: See TracTickets for help on using tickets.