Ignore:
Timestamp:
09/15/15 15:08:34 (6 years ago)
Author:
Shane Alcock <salcock@…>
Branches:
4.0.1-hotfixes, cachetimestamps, develop, dpdk-ndag, etsilive, 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:
ccb89e4
Parents:
c968cfc
Message:

Rename libtrace_get_perpkt_count to trace_get_perpkt_threads

This is to be consistent with trace_set_perpkt_threads.

Remove 'packet' parameter from the first_packet callback.
trace_get_first_packet should be used to get the first packet instead.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/combiner_unordered.c

    rf625817 ra31e166  
    77static int init_combiner(libtrace_t *t, libtrace_combine_t *c) {
    88        int i = 0;
    9         assert(libtrace_get_perpkt_count(t) > 0);
     9        assert(trace_get_perpkt_threads(t) > 0);
    1010        libtrace_queue_t *queues;
    11         c->queues = calloc(sizeof(libtrace_queue_t), libtrace_get_perpkt_count(t));
     11        c->queues = calloc(sizeof(libtrace_queue_t), trace_get_perpkt_threads(t));
    1212        queues = c->queues;
    13         for (i = 0; i < libtrace_get_perpkt_count(t); ++i) {
     13        for (i = 0; i < trace_get_perpkt_threads(t); ++i) {
    1414                libtrace_deque_init(&queues[i], sizeof(libtrace_result_t));
    1515        }
     
    3131
    3232        /* Loop through and read all that are here */
    33         for (i = 0; i < libtrace_get_perpkt_count(trace); ++i) {
     33        for (i = 0; i < trace_get_perpkt_threads(trace); ++i) {
    3434                libtrace_queue_t *v = &queues[i];
    3535                while (libtrace_deque_get_size(v) != 0) {
     
    5959        libtrace_queue_t *queues = c->queues;
    6060
    61         for (i = 0; i < libtrace_get_perpkt_count(trace); i++) {
     61        for (i = 0; i < trace_get_perpkt_threads(trace); i++) {
    6262                assert(libtrace_deque_get_size(&queues[i]) == 0);
    6363        }
Note: See TracChangeset for help on using the changeset viewer.