diff options
author | Guy Harris <guy@alum.mit.edu> | 2004-09-22 08:04:40 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2004-09-22 08:04:40 +0000 |
commit | 8dedbeed1cd700846478d9de90e0d3b2e364d684 (patch) | |
tree | b7eea02b640b90ba06f02d8699f52480ce810446 /epan/dissectors/packet-aim-location.c | |
parent | cc6754d659239dc7a1265351be5ee5c4a30171a2 (diff) |
From Jelmer Vernooij:
- Dissect the DC (Direct Connection) info structure
- Dissect the complete buddy icon family (you can now save buddy
icons as .JPG's/.PNG's directly from the capture using the "Export
selected bytes..." option!)
- Add a function that dissects a sequence of TLV's instead of having
while() loops all over the place.
svn path=/trunk/; revision=12063
Diffstat (limited to 'epan/dissectors/packet-aim-location.c')
-rw-r--r-- | epan/dissectors/packet-aim-location.c | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/epan/dissectors/packet-aim-location.c b/epan/dissectors/packet-aim-location.c index 1291d72987..7bd8f60835 100644 --- a/epan/dissectors/packet-aim-location.c +++ b/epan/dissectors/packet-aim-location.c @@ -100,20 +100,12 @@ static gint ett_aim_location = -1; static int dissect_aim_location_rightsinfo(tvbuff_t *tvb, packet_info *pinfo, proto_tree *loc_tree) { - int offset = 0; - while(tvb_length_remaining(tvb, offset) > 0) { - offset = dissect_aim_tlv(tvb, pinfo, offset, loc_tree, location_rights_tlvs); - } - return offset; + return dissect_aim_tlv_sequence(tvb, pinfo, 0, loc_tree, location_rights_tlvs); } static int dissect_aim_location_setuserinfo(tvbuff_t *tvb, packet_info *pinfo, proto_tree *loc_tree) { - int offset = 0; - while(tvb_length_remaining(tvb, offset) > 0) { - offset = dissect_aim_tlv(tvb, pinfo, offset, loc_tree, location_userinfo_tlvs); - } - return offset; + return dissect_aim_tlv_sequence(tvb, pinfo, 0, loc_tree, location_userinfo_tlvs); } static int dissect_aim_location_watcher_notification(tvbuff_t *tvb, packet_info *pinfo, proto_tree *loc_tree) @@ -176,11 +168,7 @@ static int dissect_aim_snac_location_user_information(tvbuff_t *tvb, offset = dissect_aim_tlv_list(tvb, pinfo, offset, tree, onlinebuddy_tlvs); - while(tvb_length_remaining(tvb, offset) > 0) { - offset = dissect_aim_tlv(tvb, pinfo, offset, tree, msg_tlv); - } - - return offset; + return dissect_aim_tlv_sequence(tvb, pinfo, offset, tree, msg_tlv); } static const aim_subtype aim_fnac_family_location[] = { |