Check range of supplied subframe number. If out, set back to max (9) and

add expert info error.  Should fix bug 4970.

svn path=/trunk/; revision=33432
This commit is contained in:
Martin Mathieson 2010-07-05 10:50:27 +00:00
parent 735ec2d6d2
commit b7f136ae41
1 changed files with 5 additions and 0 deletions

View File

@ -2953,6 +2953,11 @@ void dissect_mac_lte(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
ti = proto_tree_add_uint(context_tree, hf_mac_lte_context_subframe_number,
tvb, 0, 0, p_mac_lte_info->subframeNumber);
PROTO_ITEM_SET_GENERATED(ti);
if (p_mac_lte_info->subframeNumber > 9) {
expert_add_info_format(pinfo, ti, PI_MALFORMED, PI_ERROR,
"Subframe number was out of range - using max (9) instead");
p_mac_lte_info->subframeNumber = 9;
}
if (p_mac_lte_info->rntiType != NO_RNTI) {
ti = proto_tree_add_uint(context_tree, hf_mac_lte_context_rnti,