diff options
author | Guy Harris <guy@alum.mit.edu> | 2000-03-29 09:29:16 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2000-03-29 09:29:16 +0000 |
commit | 3a29d6e0901356d9da33e4603111154ced46db2f (patch) | |
tree | 58fd96131bbe43a94953687069643acc492cfc73 | |
parent | 72a70000db7b2ba753c871dbffc6584a9b5b4fbf (diff) | |
download | wireshark-3a29d6e0901356d9da33e4603111154ced46db2f.tar.gz wireshark-3a29d6e0901356d9da33e4603111154ced46db2f.tar.bz2 wireshark-3a29d6e0901356d9da33e4603111154ced46db2f.zip |
Fix from Michael Johnston to check the correct bit when testing the
broadcast flag in DHCP packets.
svn path=/trunk/; revision=1761
-rw-r--r-- | packet-bootp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/packet-bootp.c b/packet-bootp.c index 287c193e61..819a117e0b 100644 --- a/packet-bootp.c +++ b/packet-bootp.c @@ -2,7 +2,7 @@ * Routines for BOOTP/DHCP packet disassembly * Gilbert Ramirez <gram@xiexie.org> * - * $Id: packet-bootp.c,v 1.28 2000/03/20 21:39:00 gerald Exp $ + * $Id: packet-bootp.c,v 1.29 2000/03/29 09:29:16 guy Exp $ * * The information used comes from: * RFC 2132: DHCP Options and BOOTP Vendor Extensions @@ -598,7 +598,7 @@ dissect_bootp(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) proto_tree_add_item(bp_tree, hf_bootp_secs, offset + 8, 2, pntohs(&pd[offset+8])); proto_tree_add_item(bp_tree, hf_bootp_flag, - offset + 10, 2, pd[offset+10] & 1); + offset + 10, 2, pntohs(&pd[offset+10]) & 0x8000); memcpy(&ip_addr, &pd[offset+12], sizeof(ip_addr)); proto_tree_add_item(bp_tree, hf_bootp_ip_client, @@ -700,7 +700,7 @@ proto_register_bootp(void) "" }}, { &hf_bootp_flag, - { "Broadcast flag", "bootp.flag", FT_UINT16, BASE_DEC, NULL, 0x0, + { "Broadcast flag", "bootp.flag", FT_UINT16, BASE_HEX, NULL, 0x0, "" }}, { &hf_bootp_ip_client, |