aboutsummaryrefslogtreecommitdiffstats
path: root/wiretap/pcap-common.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2011-09-01 19:58:25 +0000
committerGuy Harris <guy@alum.mit.edu>2011-09-01 19:58:25 +0000
commit6ac265b51248462ffb810fd54bd6d36d35799841 (patch)
tree3d944cfa96b8c06dc4620d3c4eabe5eea3926dcf /wiretap/pcap-common.c
parent11d248331218fa16dc2622ee9794115dbf0b39c1 (diff)
Merge pcap_fill_in_pseudo_header() into pcap_read_post_process().
svn path=/trunk/; revision=38844
Diffstat (limited to 'wiretap/pcap-common.c')
-rw-r--r--wiretap/pcap-common.c21
1 files changed, 6 insertions, 15 deletions
diff --git a/wiretap/pcap-common.c b/wiretap/pcap-common.c
index c9b9ba27dc..899ad9a111 100644
--- a/wiretap/pcap-common.c
+++ b/wiretap/pcap-common.c
@@ -1623,8 +1623,9 @@ pcap_process_pseudo_header(FILE_T fh, int file_type, int wtap_encap,
}
void
-pcap_fill_in_pseudo_header(int file_type, int wtap_encap, guint8 *pd, int length,
- union wtap_pseudo_header *pseudo_header, int fcs_len)
+pcap_read_post_process(int file_type, int wtap_encap,
+ union wtap_pseudo_header *pseudo_header,
+ guint8 *pd, guint packet_size, gboolean bytes_swapped, int fcs_len)
{
switch (wtap_encap) {
@@ -1636,7 +1637,7 @@ pcap_fill_in_pseudo_header(int file_type, int wtap_encap, guint8 *pd, int length
* Guess the traffic type based on the packet
* contents.
*/
- atm_guess_traffic_type(pd, length, pseudo_header);
+ atm_guess_traffic_type(pd, packet_size, pseudo_header);
} else {
/*
* SunATM.
@@ -1646,7 +1647,8 @@ pcap_fill_in_pseudo_header(int file_type, int wtap_encap, guint8 *pd, int length
* contents.
*/
if (pseudo_header->atm.type == TRAF_LANE)
- atm_guess_lane_type(pd, length, pseudo_header);
+ atm_guess_lane_type(pd, packet_size,
+ pseudo_header);
}
break;
@@ -1654,17 +1656,6 @@ pcap_fill_in_pseudo_header(int file_type, int wtap_encap, guint8 *pd, int length
pseudo_header->eth.fcs_len = fcs_len;
break;
- default:
- break;
- }
-}
-
-void
-pcap_read_post_process(int wtap_encap, guint packet_size,
- gboolean bytes_swapped, guint8 *pd)
-{
- switch (wtap_encap) {
-
case WTAP_ENCAP_USB_LINUX:
pcap_process_linux_usb_pseudoheader(packet_size,
bytes_swapped, FALSE, pd);