Ignore:
Timestamp:
11/13/06 16:24:07 (15 years ago)
Author:
Perry Lorier <perry@…>
Branches:
4.0.1-hotfixes, cachetimestamps, develop, dpdk-ndag, etsilive, getfragoff, help, libtrace4, master, ndag_format, pfring, rc-4.0.1, rc-4.0.2, rc-4.0.3, rc-4.0.4, ringdecrementfix, ringperformance, ringtimestampfixes
Children:
6d977c9
Parents:
ef8358e
Message:
  • Support Demoting PoS traces
  • Ignore the (incorrect) ethertype field of the legacypos: traces
  • Correctly calculate the wire length for some of the legacy trace types
  • Support pausing and restarting legacy traces
File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/format_legacy.c

    r7e28dcf rbb75d10  
    9292static int erf_start_input(libtrace_t *libtrace)
    9393{
     94        if (DATA(libtrace)->input.file)
     95                return 0;
     96
    9497        DATA(libtrace)->input.file = trace_open_file(libtrace);
    9598
     
    165168static int legacypos_get_wire_length(const libtrace_packet_t *packet) {
    166169        legacy_pos_t *lpos = (legacy_pos_t *)packet->header;
    167         return ntohs(lpos->wlen);
     170        assert(ntohl(lpos->wlen)>0);
     171        return ntohl(lpos->wlen);
    168172}
    169173
Note: See TracChangeset for help on using the changeset viewer.