aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-mongo.c
diff options
context:
space:
mode:
authorJörg Mayer <jmayer@loplof.de>2013-07-23 13:38:39 +0000
committerJörg Mayer <jmayer@loplof.de>2013-07-23 13:38:39 +0000
commita74c3538fcc2dee12d657c295a0a7a49435cff77 (patch)
treea58afe4c7a42ec1d7a8efe9f4d449d5683d1e336 /epan/dissectors/packet-mongo.c
parent7e4ed00126d74e52d56c025ad6aa85dd0f73a90a (diff)
Fix for Bug 8960 - All mongodb query show as [Malformed Packet: MONGO]
proto_tree_add_item doesn't link to be called with FT_STRINGZ and length -1. svn path=/trunk/; revision=50836
Diffstat (limited to 'epan/dissectors/packet-mongo.c')
-rw-r--r--epan/dissectors/packet-mongo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/epan/dissectors/packet-mongo.c b/epan/dissectors/packet-mongo.c
index e35f8075b6..a111cccea0 100644
--- a/epan/dissectors/packet-mongo.c
+++ b/epan/dissectors/packet-mongo.c
@@ -226,8 +226,8 @@ dissect_fullcollectionname(tvbuff_t *tvb, guint offset, proto_tree *tree)
proto_item *ti;
proto_tree *fcn_tree;
- ti = proto_tree_add_item(tree, hf_mongo_fullcollectionname, tvb, offset, -1, ENC_ASCII|ENC_NA);
fcn_length = tvb_strsize(tvb, offset);
+ ti = proto_tree_add_item(tree, hf_mongo_fullcollectionname, tvb, offset, fcn_length, ENC_ASCII|ENC_NA);
/* If this doesn't find anything, we'll just throw an exception below */
dbn_length = tvb_find_guint8(tvb, offset, fcn_length, '.') - offset;