Changeset 92b3f87


Ignore:
Timestamp:
05/06/06 03:29:14 (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:
95747c3
Parents:
fe4ab68
Message:

Add supoprt for ethernet encapsulated inside LINUX_SLL frames

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/protocols.c

    r84a8828 r92b3f87  
    88#include <assert.h>
    99#include <stdio.h>
     10#include <net/if_arp.h>
    1011
    1112
     
    8687{
    8788        libtrace_sll_header_t *sll;
     89        void *ret;
    8890
    8991        sll = (libtrace_sll_header_t*) link;
     
    9799        if (*type) *type = sll->protocol;
    98100
    99         return (void*)((char*)sll+sizeof(*sll));
     101        ret=(void*)((char*)sll+sizeof(*sll));
     102
     103        switch(sll->hatype) {
     104                case ARPHRD_PPP:
     105                        break;
     106                case ARPHRD_ETHER:
     107                        ret=trace_get_payload_from_ethernet(ret,type,remaining);
     108        }
     109
     110        return ret;
    100111}
    101112
Note: See TracChangeset for help on using the changeset viewer.