diff options
author | Jaap Keuter <jaap.keuter@xs4all.nl> | 2006-08-28 19:15:08 +0000 |
---|---|---|
committer | Jaap Keuter <jaap.keuter@xs4all.nl> | 2006-08-28 19:15:08 +0000 |
commit | 6be339868d01a9e537cc9fc7df31ab2177c80593 (patch) | |
tree | 003c4d3bd896a782c2c2b5eca02043464cc2d370 /epan/dissectors/packet-udp.c | |
parent | 79221e2d947764245e5cce6520405dfdda112c52 (diff) |
Fix length check for IP packets with options.
svn path=/trunk/; revision=19062
Diffstat (limited to 'epan/dissectors/packet-udp.c')
-rw-r--r-- | epan/dissectors/packet-udp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/epan/dissectors/packet-udp.c b/epan/dissectors/packet-udp.c index 33ef6fd658..2c7384a3b3 100644 --- a/epan/dissectors/packet-udp.c +++ b/epan/dissectors/packet-udp.c @@ -288,12 +288,12 @@ dissect(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, guint32 ip_proto) switch (pinfo->src.type) { case AT_IPv4: - phdr[0] = g_htonl((ip_proto<<16) + udph->uh_ulen); + phdr[0] = g_htonl((ip_proto<<16) + reported_len); cksum_vec[2].len = 4; break; case AT_IPv6: - phdr[0] = g_htonl(udph->uh_ulen); + phdr[0] = g_htonl(reported_len); phdr[1] = g_htonl(ip_proto); cksum_vec[2].len = 8; break; |