aboutsummaryrefslogtreecommitdiffstats
path: root/epan
diff options
context:
space:
mode:
authorJaap Keuter <jaap.keuter@xs4all.nl>2010-12-19 18:46:08 +0000
committerJaap Keuter <jaap.keuter@xs4all.nl>2010-12-19 18:46:08 +0000
commit7e16ec5b991b12020f7bdc135fd4943858bc3218 (patch)
treef44173c62b5818e3bcc80e8f552887fe4d74bbc8 /epan
parent9347f11d413137fb98d4d19dc4754b3d731d6439 (diff)
Prepare for handling DLT_IPV4 and DLT_IPV6.
svn path=/trunk/; revision=35223
Diffstat (limited to 'epan')
-rw-r--r--epan/dissectors/packet-raw.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/epan/dissectors/packet-raw.c b/epan/dissectors/packet-raw.c
index 0697bc97d2..e575508de6 100644
--- a/epan/dissectors/packet-raw.c
+++ b/epan/dissectors/packet-raw.c
@@ -120,6 +120,14 @@ dissect_raw(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
proto_tree_add_text(fh_tree, tvb, 0, 0, "No link information available");
}
+ if (pinfo->fd->lnk_t == WTAP_ENCAP_RAW_IP4) {
+ call_dissector(ip_handle, tvb, pinfo, tree);
+ }
+ else if (pinfo->fd->lnk_t == WTAP_ENCAP_RAW_IP6) {
+ call_dissector(ipv6_handle, tvb, pinfo, tree);
+ }
+ else
+
/* So far, the only time we get raw connection types are with Linux and
* Irix PPP connections. We can't tell what type of data is coming down
* the line, so our safest bet is IP. - GCC
@@ -198,4 +206,6 @@ proto_reg_handoff_raw(void)
ppp_hdlc_handle = find_dissector("ppp_hdlc");
raw_handle = create_dissector_handle(dissect_raw, proto_raw);
dissector_add("wtap_encap", WTAP_ENCAP_RAW_IP, raw_handle);
+ dissector_add("wtap_encap", WTAP_ENCAP_RAW_IP4, raw_handle);
+ dissector_add("wtap_encap", WTAP_ENCAP_RAW_IP6, raw_handle);
}