Changeset 62b3c4e for lib/libtrace.h.in


Ignore:
Timestamp:
03/05/15 15:44:30 (6 years ago)
Author:
Richard Sanger <rsangerarj@…>
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:
ab3fa18
Parents:
b023181
Message:

Update the reporter method to match with the per_pkt method.

We now treat a result as a type of message.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/libtrace.h.in

    r0ec8a7c r62b3c4e  
    34613461/*@}*/
    34623462
     3463typedef struct libtrace_result_t libtrace_result_t;
    34633464/**
    34643465 * A collection of types for convenience used in place of a
     
    34713472        void *ptr;
    34723473        libtrace_packet_t *pkt;
     3474        libtrace_result_t *res;
    34733475
    34743476        /* C99 Integer types */
     
    35173519
    35183520/** Structure holding information about a result */
    3519 typedef struct libtrace_result_t {
     3521struct libtrace_result_t {
    35203522        uint64_t key;
    35213523        libtrace_generic_t value;
    35223524        int type;
    3523 } libtrace_result_t;
     3525};
    35243526#define RESULT_NORMAL 0
    35253527#define RESULT_PACKET 1
     
    35463548                            libtrace_generic_t data,
    35473549                            libtrace_thread_t *sender);
    3548 typedef void (*fn_reporter)(libtrace_t* trace, libtrace_result_t *r, libtrace_message_t *m);
     3550typedef void (*fn_reporter)(libtrace_t* trace,
     3551                            int mesg_code,
     3552                            libtrace_generic_t data,
     3553                            libtrace_thread_t *sender);
    35493554typedef uint64_t (*fn_hasher)(const libtrace_packet_t* packet, void *data);
    35503555
     
    36193624enum libtrace_messages {
    36203625        MESSAGE_PACKET,
     3626        MESSAGE_RESULT,
    36213627        MESSAGE_STARTING,
    36223628        MESSAGE_RESUMING,
Note: See TracChangeset for help on using the changeset viewer.