Changeset c0506ea for lib/libtrace_int.h


Ignore:
Timestamp:
09/20/11 14:21:53 (11 years ago)
Author:
Shane Alcock <salcock@…>
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:
c0ccccd
Parents:
2cf2c2d
Message:
  • We now use pcap_create and pcap_activate for pcap interfaces if libpcap 1.0 or later is available. This doesn't seem to make much of a difference performance-wise, as pcap_open_live was updated to use these functions anyway. This means if mmapped packet capture is available, we would have used it via pcap_open_live anyway.
  • Added a new function (trace_interrupt). Calling this function will set an internal variable which can be used to cause any blocking read_packet function to exit with an EOF. Useful for programs that are handling signals themselves and need a way to tell libtrace to stop. Prior to this, programs like tracestats would not exit on Ctrl-C if reading from a pcap interface which was not receiving any packets.
  • Updated pcap interface format to respond to trace_interrupt.
  • Optimising trace_apply_filter to minimise calls to trace_get_link_type and trace_get_packet_buffer.
  • Removed unused extern variable "form" from libtrace_int.h
  • Fixed bug with filters in the pcap interface format which would result in "invalid BPF program" error message when filter was definitely legit.
  • Updated version number to 3.0.13
File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/libtrace_int.h

    r9cc1266 rc0506ea  
    762762
    763763/** The list of registered capture formats */
    764 extern struct libtrace_format_t *form;
     764//extern struct libtrace_format_t *form;
     765
     766/** Specifies whether any blocking packet readers should cease reading
     767 * immediately
     768 */
     769extern int libtrace_halt;
    765770
    766771/** Registers a new capture format module.
Note: See TracChangeset for help on using the changeset viewer.