Wireshark-dev: [Wireshark-dev] Re: On dissection of GSM A DTAP BCC Call State

From: Pascal Quantin <pascal@xxxxxxxxxxxxx>
Date: Mon, 10 Mar 2025 09:54:24 +0100
Hi Jaap,

Le dim. 9 mars 2025 à 17:12, Jaap Keuter <jaap.keuter@xxxxxxxxx> a écrit :
Hi,

When stumbling on packet-gsm_a_dtap.c:de_bcc_call_state() I became thoroughly
confused. What size are we handling here?

1)

de_bcc_call_state() returns 1, indicating that only _one_ octet is consumed.

2)

de_bcc_call_state() contains the following statement
proto_tree_add_item(tree, hf_gsm_a_dtap_bcc_call_state, tvb, offset, 2, ENC_NA);
adding a _two_ octet field to the tree.

3)

The field definition hf_gsm_a_dtap_bcc_call_state has the FT_UINT24 field type,
indicating a _three_ octet field.


Which one is it? Which of these three is wrong?
TS 144 069 V11.0.0 section 8.6 suggests it's a single octet, so I think 1) is
correct, but like to have confirmation.

I agree with your analysis, the correct width should be 1.

Cheers,
Pascal.