aboutsummaryrefslogtreecommitdiffstats
path: root/asn1/atn-ulcs
diff options
context:
space:
mode:
authorAndersBroman <anders.broman@ericsson.com>2014-05-20 12:54:20 +0200
committerAnders Broman <a.broman58@gmail.com>2014-05-21 20:17:29 +0000
commit2cfda31ff09893bd8c59acabc8faad7227f52ede (patch)
treea0bee1c33fe7bc2eeced9c2f7fe0bbe7628cebcd /asn1/atn-ulcs
parentbb01c7ac380a2978d8e1c5ca8fa7f2dd523a8323 (diff)
Change the signature of dissector_try_heuristic() to return hdtbl_entry
which can be used to call the found heuristic dissector on the next pass. Introduce call_heur_dissector_direct() to be used to call a heuristic dissector which accepted the frame on the first pass. Change-Id: I524edd717b7d92b510bd60acfeea686d5f2b4582 Reviewed-on: https://code.wireshark.org/review/1697 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'asn1/atn-ulcs')
-rw-r--r--asn1/atn-ulcs/atn-ulcs.cnf8
-rw-r--r--asn1/atn-ulcs/packet-atn-ulcs-template.c2
2 files changed, 8 insertions, 2 deletions
diff --git a/asn1/atn-ulcs/atn-ulcs.cnf b/asn1/atn-ulcs/atn-ulcs.cnf
index 5ec06ab0e3..4307146488 100644
--- a/asn1/atn-ulcs/atn-ulcs.cnf
+++ b/asn1/atn-ulcs/atn-ulcs.cnf
@@ -49,6 +49,7 @@ PDV-list/presentation-data-values/arbitrary pdv-list_presentation-data-values_ar
proto_item *ti = NULL;
proto_tree *atn_ulcs_tree = NULL;
atn_conversation_t *atn_cv = NULL;
+ heur_dtbl_entry_t *hdtbl_entry;
/* extract bitstring into new tvb buffer */
offset = dissect_per_bit_string(
@@ -113,6 +114,7 @@ PDV-list/presentation-data-values/arbitrary pdv-list_presentation-data-values_ar
tvb_new_subset_remaining(tvb_usr,0),
actx->pinfo,
root_tree,
+ &hdtbl_entry,
NULL);
break;
}
@@ -123,6 +125,7 @@ PDV-list/presentation-data-values/arbitrary pdv-list_presentation-data-values_ar
tvb_new_subset_remaining(tvb_usr,0),
actx->pinfo,
root_tree,
+ &hdtbl_entry,
NULL);
}
break;
@@ -458,6 +461,7 @@ PDV-list/presentation-data-values/arbitrary pdv-list_presentation-data-values_ar
tvbuff_t *tvb_usr = NULL;
packet_info * pinfo = actx->pinfo;
atn_conversation_t *atn_cv = NULL;
+ heur_dtbl_entry_t *hdtbl_entry;
/* decode bit-string user data within ACSE */
offset = dissect_per_bit_string(
@@ -525,6 +529,7 @@ PDV-list/presentation-data-values/arbitrary pdv-list_presentation-data-values_ar
tvb_new_subset_remaining(tvb_usr,0),
actx->pinfo,
root_tree,
+ &hdtbl_entry,
NULL);
break;
}
@@ -535,11 +540,12 @@ PDV-list/presentation-data-values/arbitrary pdv-list_presentation-data-values_ar
tvb_new_subset_remaining(tvb_usr,0),
actx->pinfo,
root_tree,
+ &hdtbl_entry,
NULL);
}
}
- offset += tvb_length_remaining(tvb, offset);
+ offset += tvb_reported_length_remaining(tvb, offset);
#.END
diff --git a/asn1/atn-ulcs/packet-atn-ulcs-template.c b/asn1/atn-ulcs/packet-atn-ulcs-template.c
index 0445b29e05..3350d18f32 100644
--- a/asn1/atn-ulcs/packet-atn-ulcs-template.c
+++ b/asn1/atn-ulcs/packet-atn-ulcs-template.c
@@ -746,7 +746,7 @@ static gboolean dissect_atn_ulcs_heur(
{
/* do we have enough data*/
/* at least session + presentation data or pdv-list */
- if (tvb_length(tvb) < 2){
+ if (tvb_captured_length(tvb) < 2){
return FALSE; }
/* check for session/presentation/ACSE PDU's */