diff options
author | Gilbert Ramirez <gram@alumni.rice.edu> | 1998-11-20 17:47:33 +0000 |
---|---|---|
committer | Gilbert Ramirez <gram@alumni.rice.edu> | 1998-11-20 17:47:33 +0000 |
commit | 2b7cb49995452e40563fc1b7f29068debdae775f (patch) | |
tree | 5cca72946e004d51495e096e35e857c5f0c7be0c /packet-bootp.c | |
parent | c1902f17ea7fd3c4b636eac22ecad9d8077821bb (diff) | |
download | wireshark-2b7cb49995452e40563fc1b7f29068debdae775f.tar.gz |
Fix for non null-terminated strings.
svn path=/trunk/; revision=115
Diffstat (limited to 'packet-bootp.c')
-rw-r--r-- | packet-bootp.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/packet-bootp.c b/packet-bootp.c index f0ef1b245a..f9430f36b4 100644 --- a/packet-bootp.c +++ b/packet-bootp.c @@ -2,7 +2,7 @@ * Routines for BOOTP/DHCP packet disassembly * Gilbert Ramirez <gram@verdict.uthscsa.edu> * - * $Id: packet-bootp.c,v 1.13 1998/11/20 04:34:37 gram Exp $ + * $Id: packet-bootp.c,v 1.14 1998/11/20 17:47:33 gram Exp $ * * The information used comes from: * RFC 2132: DHCP Options and BOOTP Vendor Extensions @@ -326,8 +326,11 @@ bootp_option(const u_char *pd, GtkWidget *bp_tree, int voff, int eoff) break; case string: + /* Fix for non null-terminated string supplied by + * John Lines <John.Lines@aeat.co.uk> + */ add_item_to_tree(bp_tree, voff, consumed, - "Option %d: %s = %.*s", code, text, pd[voff+2], &pd[voff+2]); + "Option %d: %s = %.*s", code, text, vlen, &pd[voff+2]); break; case opaque: |