MAC LTE: fix dissection of Extended PHR Control Element

It has the same value as the DL SC-MCCH/SC-MTCH CE, so take into account direction

Change-Id: I75848f92342cfc67f2e6aee1f8bc42616e662cdc
Reviewed-on: https://code.wireshark.org/review/18183
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
This commit is contained in:
Pascal Quantin 2016-10-13 14:10:26 +02:00
parent 4f6ed3852d
commit 7ce85a92f9
1 changed files with 4 additions and 4 deletions

View File

@ -4296,14 +4296,13 @@ static void dissect_ulsch_or_dlsch(tvbuff_t *tvb, packet_info *pinfo, proto_tree
have_seen_data_header = TRUE;
expecting_body_data = TRUE;
}
if (lcids[number_of_headers] == SC_MCCH_SC_MTCH_LCID) {
if ((p_mac_lte_info->direction == DIRECTION_DOWNLINK) && (lcids[number_of_headers] == SC_MCCH_SC_MTCH_LCID)) {
have_seen_sc_mcch_sc_mtch_header = TRUE;
}
/* Show an expert item if a control subheader (except Padding) appears
*after* a data PDU */
if (have_seen_data_header && (lcids[number_of_headers] > 10) &&
(lcids[number_of_headers] != PADDING_LCID) && (lcids[number_of_headers] != SC_MCCH_SC_MTCH_LCID)) {
if (have_seen_data_header && (lcids[number_of_headers] > 10) && (lcids[number_of_headers] != PADDING_LCID)) {
expert_add_info_format(pinfo, lcid_ti, &ei_mac_lte_control_subheader_after_data_subheader,
"%cL-SCH control subheaders should not appear after data subheaders",
(p_mac_lte_info->direction == DIRECTION_UPLINK) ? 'U' : 'D');
@ -4512,7 +4511,8 @@ static void dissect_ulsch_or_dlsch(tvbuff_t *tvb, packet_info *pinfo, proto_tree
for (n=0; n < number_of_headers; n++) {
/* Get out of loop once see any data SDU subheaders */
if ((lcids[n] <= 10) || (lcids[n] == SC_MCCH_SC_MTCH_LCID)) {
if ((lcids[n] <= 10) ||
((p_mac_lte_info->direction == DIRECTION_DOWNLINK) && (lcids[n] == SC_MCCH_SC_MTCH_LCID))) {
break;
}