aboutsummaryrefslogtreecommitdiffstats
path: root/asn1/atn-cpdlc
diff options
context:
space:
mode:
authorPascal Quantin <pascal.quantin@gmail.com>2013-09-08 21:10:36 +0000
committerPascal Quantin <pascal.quantin@gmail.com>2013-09-08 21:10:36 +0000
commita6ae13dee97af192794a604f348a31b505926d47 (patch)
tree06bcd607342049eda2d55dabf84f5fa72014776b /asn1/atn-cpdlc
parent54adc0d2ffe70561ffbe8b38a4bc36e33ef9ae0d (diff)
Slightly different fix for https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9117 :
Check that tvb returned by dissect_per_bit_string is not null before trying to use it svn path=/trunk/; revision=51846
Diffstat (limited to 'asn1/atn-cpdlc')
-rw-r--r--asn1/atn-cpdlc/atn-cpdlc.cnf20
1 files changed, 11 insertions, 9 deletions
diff --git a/asn1/atn-cpdlc/atn-cpdlc.cnf b/asn1/atn-cpdlc/atn-cpdlc.cnf
index bf6555a028..3f7efbb4e8 100644
--- a/asn1/atn-cpdlc/atn-cpdlc.cnf
+++ b/asn1/atn-cpdlc/atn-cpdlc.cnf
@@ -60,15 +60,17 @@ ProtectedAircraftPDUs/startdown protectedstartDownmessage
offset = dissect_per_bit_string(tvb, offset, actx, tree, hf_index, NO_BOUND, NO_BOUND, FALSE, &tvb_usr);
- switch(check_heur_msg_type(actx->pinfo)){
- case dm:
- dissect_atn_cpdlc_ATCDownlinkMessage(tvb_new_subset_remaining(tvb_usr, 0), 0, actx, tree, hf_index);
- break;
- case um:
- dissect_atn_cpdlc_ATCUplinkMessage(tvb_new_subset_remaining(tvb_usr, 0), 0, actx , tree, hf_index);
- break;
- default:
- break;
+ if (tvb_usr) {
+ switch(check_heur_msg_type(actx->pinfo)){
+ case dm:
+ dissect_atn_cpdlc_ATCDownlinkMessage(tvb_new_subset_remaining(tvb_usr, 0), 0, actx, tree, hf_index);
+ break;
+ case um:
+ dissect_atn_cpdlc_ATCUplinkMessage(tvb_new_subset_remaining(tvb_usr, 0), 0, actx , tree, hf_index);
+ break;
+ default:
+ break;
+ }
}
#.END