aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--asn1/atn-ulcs/atn-ulcs.cnf116
-rw-r--r--epan/dissectors/packet-atn-ulcs.c116
2 files changed, 118 insertions, 114 deletions
diff --git a/asn1/atn-ulcs/atn-ulcs.cnf b/asn1/atn-ulcs/atn-ulcs.cnf
index f7b0b4735d..d765411201 100644
--- a/asn1/atn-ulcs/atn-ulcs.cnf
+++ b/asn1/atn-ulcs/atn-ulcs.cnf
@@ -469,72 +469,74 @@ PDV-list/presentation-data-values/arbitrary pdv-list_presentation-data-values_ar
FALSE,
&tvb_usr);
- /* DT: dstref present, srcref is always zero */
- if((pinfo->clnp_dstref) && (!pinfo->clnp_srcref)){
+ if (tvb_usr) {
+ /* DT: dstref present, srcref is always zero */
+ if((pinfo->clnp_dstref) && (!pinfo->clnp_srcref)){
- atn_cv = find_atn_conversation(
- &pinfo->dst,
- pinfo->clnp_dstref,
- &pinfo->src);
- }
- /* CR: srcref present, dstref always zero */
- if((pinfo->clnp_srcref) && (!pinfo->clnp_dstref)){
+ atn_cv = find_atn_conversation(
+ &pinfo->dst,
+ pinfo->clnp_dstref,
+ &pinfo->src);
+ }
+ /* CR: srcref present, dstref always zero */
+ if((pinfo->clnp_srcref) && (!pinfo->clnp_dstref)){
- atn_cv = find_atn_conversation(
- &pinfo->src,
- pinfo->clnp_srcref,
- &pinfo->dst);
- }
- /* CC: srcref and dstref present */
- if((pinfo->clnp_srcref) && (pinfo->clnp_dstref)){
+ atn_cv = find_atn_conversation(
+ &pinfo->src,
+ pinfo->clnp_srcref,
+ &pinfo->dst);
+ }
+ /* CC: srcref and dstref present */
+ if((pinfo->clnp_srcref) && (pinfo->clnp_dstref)){
- atn_cv = find_atn_conversation(
- &pinfo->src,
- pinfo->clnp_srcref,
- &pinfo->dst);
- }
+ atn_cv = find_atn_conversation(
+ &pinfo->src,
+ pinfo->clnp_srcref,
+ &pinfo->dst);
+ }
- if(atn_cv) {
- switch(atn_cv->ae_qualifier){
- case cma: /* contact management */
+ if(atn_cv) {
+ switch(atn_cv->ae_qualifier){
+ case cma: /* contact management */
- call_dissector_with_data(
- atn_cm_handle,
- tvb_new_subset_remaining(tvb_usr, 0),
- pinfo,
- root_tree,
- NULL);
- break;
- case cpdlc: /* plain old cpdlc */
- case pmcpdlc: /* protected mode cpdlc */
+ call_dissector_with_data(
+ atn_cm_handle,
+ tvb_new_subset_remaining(tvb_usr, 0),
+ pinfo,
+ root_tree,
+ NULL);
+ break;
+ case cpdlc: /* plain old cpdlc */
+ case pmcpdlc: /* protected mode cpdlc */
+
+ call_dissector_with_data(
+ atn_cpdlc_handle,
+ tvb_new_subset_remaining(tvb_usr, 0),
+ pinfo,
+ root_tree,
+ NULL);
+ break;
+ default: /* unknown or unhandled datalink application */
- call_dissector_with_data(
- atn_cpdlc_handle,
- tvb_new_subset_remaining(tvb_usr, 0),
- pinfo,
+ dissector_try_heuristic(
+ atn_ulcs_heur_subdissector_list,
+ tvb_new_subset_remaining(tvb_usr,0),
+ actx->pinfo,
root_tree,
NULL);
- break;
- default: /* unknown or unhandled datalink application */
-
- dissector_try_heuristic(
- atn_ulcs_heur_subdissector_list,
- tvb_new_subset_remaining(tvb_usr,0),
- actx->pinfo,
- root_tree,
- NULL);
- break;
- }
- }else {
-
- dissector_try_heuristic(
- atn_ulcs_heur_subdissector_list,
- tvb_new_subset_remaining(tvb_usr,0),
- actx->pinfo,
- root_tree,
- NULL);
+ break;
+ }
+ }else {
+
+ dissector_try_heuristic(
+ atn_ulcs_heur_subdissector_list,
+ tvb_new_subset_remaining(tvb_usr,0),
+ actx->pinfo,
+ root_tree,
+ NULL);
+ }
}
-
+
offset += tvb_length_remaining(tvb, offset);
#.END
diff --git a/epan/dissectors/packet-atn-ulcs.c b/epan/dissectors/packet-atn-ulcs.c
index 74a2f58e56..cd41c20dc6 100644
--- a/epan/dissectors/packet-atn-ulcs.c
+++ b/epan/dissectors/packet-atn-ulcs.c
@@ -600,72 +600,74 @@ dissect_atn_ulcs_T_externalt_encoding_arbitrary(tvbuff_t *tvb _U_, int offset _U
FALSE,
&tvb_usr);
- /* DT: dstref present, srcref is always zero */
- if((pinfo->clnp_dstref) && (!pinfo->clnp_srcref)){
+ if (tvb_usr) {
+ /* DT: dstref present, srcref is always zero */
+ if((pinfo->clnp_dstref) && (!pinfo->clnp_srcref)){
- atn_cv = find_atn_conversation(
- &pinfo->dst,
- pinfo->clnp_dstref,
- &pinfo->src);
- }
- /* CR: srcref present, dstref always zero */
- if((pinfo->clnp_srcref) && (!pinfo->clnp_dstref)){
+ atn_cv = find_atn_conversation(
+ &pinfo->dst,
+ pinfo->clnp_dstref,
+ &pinfo->src);
+ }
+ /* CR: srcref present, dstref always zero */
+ if((pinfo->clnp_srcref) && (!pinfo->clnp_dstref)){
- atn_cv = find_atn_conversation(
- &pinfo->src,
- pinfo->clnp_srcref,
- &pinfo->dst);
- }
- /* CC: srcref and dstref present */
- if((pinfo->clnp_srcref) && (pinfo->clnp_dstref)){
+ atn_cv = find_atn_conversation(
+ &pinfo->src,
+ pinfo->clnp_srcref,
+ &pinfo->dst);
+ }
+ /* CC: srcref and dstref present */
+ if((pinfo->clnp_srcref) && (pinfo->clnp_dstref)){
- atn_cv = find_atn_conversation(
- &pinfo->src,
- pinfo->clnp_srcref,
- &pinfo->dst);
- }
+ atn_cv = find_atn_conversation(
+ &pinfo->src,
+ pinfo->clnp_srcref,
+ &pinfo->dst);
+ }
- if(atn_cv) {
- switch(atn_cv->ae_qualifier){
- case cma: /* contact management */
+ if(atn_cv) {
+ switch(atn_cv->ae_qualifier){
+ case cma: /* contact management */
- call_dissector_with_data(
- atn_cm_handle,
- tvb_new_subset_remaining(tvb_usr, 0),
- pinfo,
- root_tree,
- NULL);
- break;
- case cpdlc: /* plain old cpdlc */
- case pmcpdlc: /* protected mode cpdlc */
+ call_dissector_with_data(
+ atn_cm_handle,
+ tvb_new_subset_remaining(tvb_usr, 0),
+ pinfo,
+ root_tree,
+ NULL);
+ break;
+ case cpdlc: /* plain old cpdlc */
+ case pmcpdlc: /* protected mode cpdlc */
+
+ call_dissector_with_data(
+ atn_cpdlc_handle,
+ tvb_new_subset_remaining(tvb_usr, 0),
+ pinfo,
+ root_tree,
+ NULL);
+ break;
+ default: /* unknown or unhandled datalink application */
- call_dissector_with_data(
- atn_cpdlc_handle,
- tvb_new_subset_remaining(tvb_usr, 0),
- pinfo,
+ dissector_try_heuristic(
+ atn_ulcs_heur_subdissector_list,
+ tvb_new_subset_remaining(tvb_usr,0),
+ actx->pinfo,
root_tree,
NULL);
- break;
- default: /* unknown or unhandled datalink application */
-
- dissector_try_heuristic(
- atn_ulcs_heur_subdissector_list,
- tvb_new_subset_remaining(tvb_usr,0),
- actx->pinfo,
- root_tree,
- NULL);
- break;
- }
- }else {
-
- dissector_try_heuristic(
- atn_ulcs_heur_subdissector_list,
- tvb_new_subset_remaining(tvb_usr,0),
- actx->pinfo,
- root_tree,
- NULL);
+ break;
+ }
+ }else {
+
+ dissector_try_heuristic(
+ atn_ulcs_heur_subdissector_list,
+ tvb_new_subset_remaining(tvb_usr,0),
+ actx->pinfo,
+ root_tree,
+ NULL);
+ }
}
-
+
offset += tvb_length_remaining(tvb, offset);