Changeset 222d8f5 for lib/trace.c


Ignore:
Timestamp:
04/21/06 11:09:28 (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:
e9ee974
Parents:
39e141f
Message:

More bug fixes, now erf works again properly

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/trace.c

    r39e141f r222d8f5  
    617617        packet->trace = libtrace;
    618618
    619 
    620619        if (libtrace->format->read_packet) {
    621620                do {
    622621                        packet->size=libtrace->format->read_packet(libtrace,packet);
    623                         if (packet->size==(size_t)-1 || packet->size==0)
     622                        if (packet->size==(size_t)-1 || packet->size==0) {
    624623                                return packet->size;
     624                        }
    625625                        if (libtrace->filter) {
    626626                                /* If the filter doesn't match, read another
     
    636636                                                libtrace->snaplen);
    637637                        }
    638 
    639638                        return packet->size;
    640639                } while(1);
    641640        }
     641        trace_set_err(libtrace,TRACE_ERR_BAD_FORMAT,"This format does not support reading packets\n");
    642642        packet->size=-1;
    643643        return -1;
Note: See TracChangeset for help on using the changeset viewer.