diff options
author | Mikhail Koreshkov <drkor@hotbox.ru> | 2015-03-24 22:17:30 +0300 |
---|---|---|
committer | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2015-03-24 20:02:59 +0000 |
commit | 6545d199cc7579fcb840f6453f28aa4b9f56c7dd (patch) | |
tree | 8dce2e97c7521b2ba61cc86cb1e6c099c7e4eaed /epan | |
parent | cc4bce537bdd92ec10c0bf26432f3bb2396ac4a6 (diff) |
Q931: Dissect IEC/ISO cause coding standard as ITU-T
Add preference to enable dissect IEC/ISO cause coding as ITU-T (Q.850)
Change-Id: Id61f0785b8355f1aed03c4dea70657d661af3f11
Reviewed-on: https://code.wireshark.org/review/7806
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Diffstat (limited to 'epan')
-rw-r--r-- | epan/dissectors/packet-q931.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/epan/dissectors/packet-q931.c b/epan/dissectors/packet-q931.c index 720d7460a1..3da40991fb 100644 --- a/epan/dissectors/packet-q931.c +++ b/epan/dissectors/packet-q931.c @@ -235,6 +235,7 @@ static reassembly_table q931_reassembly_table; /* Preferences */ static gboolean q931_reassembly = TRUE; +static gboolean g931_iso_iec_cause = FALSE; static dissector_table_t codeset_dissector_table; static dissector_table_t ie_dissector_table; @@ -585,6 +586,7 @@ static const value_string q931_repeat_indication_vals[] = { * ITU-standardized coding. */ #define Q931_ITU_STANDARDIZED_CODING 0x00 +#define Q931_ISO_IEC_STANDARDIZED_CODING 0x01 /* * Dissect a Segmented message information element. @@ -1283,7 +1285,8 @@ dissect_q931_cause_ie_unsafe(tvbuff_t *tvb, int offset, int len, return; octet = tvb_get_guint8(tvb, offset); coding_standard = octet & 0x60; - if (coding_standard != Q931_ITU_STANDARDIZED_CODING) { + if (coding_standard != Q931_ITU_STANDARDIZED_CODING && + !g931_iso_iec_cause && coding_standard != Q931_ISO_IEC_STANDARDIZED_CODING) { /* * We don't know how the cause is encoded, * so just dump it as data and be done with it. @@ -3868,6 +3871,10 @@ proto_register_q931(void) "Reassemble segmented Q.931 messages", "Reassemble segmented Q.931 messages (Q.931 - Annex H)", &q931_reassembly); + prefs_register_bool_preference(q931_module, "iso_iec_cause_coding", + "Decode ISO/IEC cause coding standard as ITU-T", + "Decode ISO/IEC cause coding standard as ITU-T", + &g931_iso_iec_cause); /* Register for tapping */ q931_tap = register_tap("q931"); } |