summaryrefslogtreecommitdiff
path: root/packet.c
diff options
context:
space:
mode:
authorGilbert Ramirez <gram@alumni.rice.edu>1999-01-02 06:10:55 +0000
committerGilbert Ramirez <gram@alumni.rice.edu>1999-01-02 06:10:55 +0000
commit3688d96c459a5847a49d14264c0398600379f8b9 (patch)
treef87737491cb959697c6414b4ea1745e7528c1acc /packet.c
parentd1a7effcf97733edfac7ea145cccddc1032cbf6f (diff)
downloadwireshark-3688d96c459a5847a49d14264c0398600379f8b9.tar.gz
Added the iptrace (AIX's packet-capture tool) file format to wiretap.
This necessitated a change in ethereal because iptrace supports multi-NIC packet capturing, including multi-datalink-type capturing. svn path=/trunk/; revision=145
Diffstat (limited to 'packet.c')
-rw-r--r--packet.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/packet.c b/packet.c
index b368e134e1..3ddcfaee68 100644
--- a/packet.c
+++ b/packet.c
@@ -1,7 +1,7 @@
/* packet.c
* Routines for packet disassembly
*
- * $Id: packet.c,v 1.15 1998/12/29 04:05:36 gerald Exp $
+ * $Id: packet.c,v 1.16 1999/01/02 06:10:53 gram Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@@ -310,6 +310,9 @@ dissect_packet(const u_char *pd, frame_data *fd, GtkTree *tree)
GtkWidget *fh_tree, *ti;
struct tm *tmp;
time_t then;
+#ifdef WITH_WIRETAP
+ guint32 lnk_t;
+#endif
/* Put in frame header information. */
if (check_col(fd, COL_ABS_TIME)) {
@@ -354,7 +357,14 @@ dissect_packet(const u_char *pd, frame_data *fd, GtkTree *tree)
}
#ifdef WITH_WIRETAP
- switch (cf.lnk_t) {
+ if (cf.lnk_t == WTAP_ENCAP_PER_PACKET) {
+ lnk_t = fd->lnk_t;
+ }
+ else {
+ lnk_t = cf.lnk_t;
+ }
+
+ switch (lnk_t) {
case WTAP_ENCAP_ETHERNET :
dissect_eth(pd, fd, tree);
break;