Changeset de3d203


Ignore:
Timestamp:
04/08/08 15:34:42 (14 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:
cdcaef6
Parents:
8a0e6e8
Message:

Make sure that the length cache is cleared when we end up consuming multiple
packets in read_packet()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/trace.c

    rf0fb38f rde3d203  
    729729        }
    730730
    731         /* Clear the packet cache */
    732         packet->capture_length = -1;
    733         packet->l3_header = NULL;
    734         packet->l3_ethertype = 0;
    735731
    736732        if (libtrace->format->read_packet) {
    737733                do {
    738734                        size_t ret;
     735                        /* Clear the packet cache */
     736                        packet->capture_length = -1;
     737                        packet->l3_header = NULL;
     738                        packet->l3_ethertype = 0;
     739
    739740                        ret=libtrace->format->read_packet(libtrace,packet);
    740741                        if (ret==(size_t)-1 || ret==0) {
Note: See TracChangeset for help on using the changeset viewer.