- Timestamp:
- 05/06/06 02:24:13 (16 years ago)
- 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:
- fe4ab68
- Parents:
- b721834
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lib/linktypes.c
rb721834 rd4c8b343 102 102 return; /* Unnecessary */ 103 103 104 case TRACE_TYPE_NONE: 104 105 case TRACE_TYPE_ETH: 105 106 /* This should be easy, just prepend the header */ … … 113 114 114 115 hdr->pkttype=0; /* "outgoing" */ 115 hdr->hatype = ARPHRD_ETHER; 116 if (pcap_dlt_to_libtrace(rt_to_pcap_dlt(packet->type))==TRACE_TYPE_ETH) 117 hdr->hatype = ARPHRD_ETHER; 118 else 119 hdr->hatype = ARPHRD_PPP; 120 trace_get_payload_from_link( 121 trace_get_link(packet), 122 trace_get_link_type(packet), 123 &hdr->protocol, 124 NULL); 116 125 break; 117 126 default: … … 135 144 packet->header=tmpbuffer; 136 145 packet->payload=tmpbuffer+trace_get_framing_length(packet); 137 packet->type= TRACE_TYPE_LINUX_SLL;146 packet->type=pcap_dlt_to_rt(TRACE_DLT_LINUX_SLL); 138 147 return; 139 148 }
Note: See TracChangeset
for help on using the changeset viewer.