From Pascal Quantin:
authoretxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7>
Wed, 28 Jul 2010 21:13:05 +0000 (21:13 +0000)
committeretxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7>
Wed, 28 Jul 2010 21:13:05 +0000 (21:13 +0000)
The attached patch fixes the dissection of the PDN Disconnect Request message
in case the optional Protocol Configuration Options IE is not present.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5065

git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@33654 f5534014-38df-0310-8fa8-9805f1628bb7

epan/dissectors/packet-nas_eps.c

index 0cdac5c8927655cc0d5caab4c1b3ebb217ca7474..97cd0a3a8612650438dd9a3ebb69bd8ff746d011 100644 (file)
@@ -3872,6 +3872,8 @@ nas_esm_pdn_disc_req(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
        /* Fix the lengths */
        curr_len--;
        curr_offset++;
+       if (curr_len == 0)
+               return;
        /* 27   Protocol configuration options  Protocol configuration options 9.9.4.11 O       TLV     3-253 */
        ELEM_OPT_TLV( 0x27 , GSM_A_PDU_TYPE_GM, DE_PRO_CONF_OPT , "" );