diff options
author | Gerald Combs <gerald@wireshark.org> | 2005-06-20 19:35:58 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2005-06-20 19:35:58 +0000 |
commit | 3a6c9ab13448b557586a427bd025bc1ff99ac4cc (patch) | |
tree | 0bc3f2c2b25520d8672dc5a055f3181818019400 /epan/dissectors/packet-ncp2222.inc | |
parent | c3cfe365cfdecc58122b8042797d58004e2297f3 (diff) |
Fix a format string vulneratility in the AFP dissector identified
by iDEFENSE. Add constant format strings to proto_item_append_text()
in a bunch of other dissectors. Copy a comment from proto.c to proto.h.
svn path=/trunk/; revision=14713
Diffstat (limited to 'epan/dissectors/packet-ncp2222.inc')
-rw-r--r-- | epan/dissectors/packet-ncp2222.inc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-ncp2222.inc b/epan/dissectors/packet-ncp2222.inc index 5bf24b2b4d..9f462241c9 100644 --- a/epan/dissectors/packet-ncp2222.inc +++ b/epan/dissectors/packet-ncp2222.inc @@ -1142,7 +1142,7 @@ padd_date(ptvcursor_t *ptvc, const ptvc_record *rec) uint_to_nwdate(get_item_value(item), &nw_date); - proto_item_set_text(item, get_item_name(item)); + proto_item_set_text(item, "%s", get_item_name(item)); proto_item_append_text(item, ": %04u/%02u/%02u", nw_date.year, nw_date.month, nw_date.day); return item; @@ -1162,7 +1162,7 @@ padd_time(ptvcursor_t *ptvc, const ptvc_record *rec) uint_to_nwtime(get_item_value(item), &nw_time); - proto_item_set_text(item, get_item_name(item)); + proto_item_set_text(item, "%s", get_item_name(item)); proto_item_append_text(item, ": %02u:%02u:%02u", nw_time.hour, nw_time.minute, nw_time.second); return item; @@ -1185,7 +1185,7 @@ padd_uni(ptvcursor_t *ptvc, const ptvc_record *rec) item = ptvcursor_add(ptvc, *rec->hf_ptr, rec->length, rec->endianness); - proto_item_set_text(item, get_item_name(item)); + proto_item_set_text(item, "%s", get_item_name(item)); proto_item_append_text(item, " %s", nw_uni.buffer); |