aboutsummaryrefslogtreecommitdiffstats
path: root/asn1/tcap
diff options
context:
space:
mode:
authorJeff Morriss <jeff.morriss@ulticom.com>2007-07-30 17:10:20 +0000
committerJeff Morriss <jeff.morriss@ulticom.com>2007-07-30 17:10:20 +0000
commit7c4cca3e63903940fc98f3f967159fe0453e2590 (patch)
tree9141381476f1dee0a9a8c6e27f458c07e70ab926 /asn1/tcap
parent9636fdfefd44bd4105c893928a6f4359e68c9fe0 (diff)
From Florent Drouin:
Correct bug in TCAP statistics when read filter is used. Rename the TCAP decoding functions to show which are ITU vs. ANSI. Don't unregister an ITU SSN if it's used by an ANSI subdissector. svn path=/trunk/; revision=22421
Diffstat (limited to 'asn1/tcap')
-rw-r--r--asn1/tcap/packet-tcap-template.c14
-rw-r--r--asn1/tcap/tcap.cnf4
2 files changed, 10 insertions, 8 deletions
diff --git a/asn1/tcap/packet-tcap-template.c b/asn1/tcap/packet-tcap-template.c
index 6dd48db063..960ce6c747 100644
--- a/asn1/tcap/packet-tcap-template.c
+++ b/asn1/tcap/packet-tcap-template.c
@@ -103,8 +103,8 @@ static dissector_table_t sccp_ssn_table;
static void raz_tcap_private(struct tcap_private_t * p_tcap_private);
static int dissect_tcap_param(asn1_ctx_t *actx, proto_tree *tree, tvbuff_t *tvb, int offset);
static int dissect_tcap_UserInformation(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_);
-static int dissect_tcap_TheComponent(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_);
-static int dissect_tcap_TheComponentPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_);
+static int dissect_tcap_ITU_ComponentPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_);
+static int dissect_tcap_ANSI_ComponentPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_);
static int dissect_tcap_TheExternUserInfo(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset,asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_);
static GHashTable* ansi_sub_dissectors = NULL;
@@ -124,11 +124,13 @@ extern void add_itu_tcap_subdissector(guint32 ssn, dissector_handle_t dissector)
extern void delete_ansi_tcap_subdissector(guint32 ssn, dissector_handle_t dissector _U_) {
g_hash_table_remove(ansi_sub_dissectors,GUINT_TO_POINTER(ssn));
- dissector_delete("sccp.ssn",ssn,tcap_handle);
+ if (!get_itu_tcap_subdissector(ssn))
+ dissector_delete("sccp.ssn",ssn,tcap_handle);
}
extern void delete_itu_tcap_subdissector(guint32 ssn, dissector_handle_t dissector _U_) {
g_hash_table_remove(itu_sub_dissectors,GUINT_TO_POINTER(ssn));
- dissector_delete("sccp.ssn", ssn,tcap_handle);
+ if (!get_ansi_tcap_subdissector(ssn))
+ dissector_delete("sccp.ssn", ssn,tcap_handle);
}
dissector_handle_t get_ansi_tcap_subdissector(guint32 ssn) {
@@ -475,7 +477,7 @@ static void raz_tcap_private(struct tcap_private_t * p_tcap_private)
* Call ITU Subdissector to decode the Tcap Component
*/
static int
-dissect_tcap_TheComponent(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_)
+dissect_tcap_ITU_ComponentPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_)
{
dissector_handle_t subdissector_handle=NULL;
gboolean is_subdissector=FALSE;
@@ -607,7 +609,7 @@ dissect_tcap_TheComponent(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset,
* Call ANSI Subdissector to decode the Tcap Component
*/
static int
-dissect_tcap_TheComponentPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_)
+dissect_tcap_ANSI_ComponentPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_, proto_tree *tree, int hf_index _U_)
{
dissector_handle_t subdissector_handle;
gboolean is_subdissector=FALSE;
diff --git a/asn1/tcap/tcap.cnf b/asn1/tcap/tcap.cnf
index 9a1663945a..b9069665a6 100644
--- a/asn1/tcap/tcap.cnf
+++ b/asn1/tcap/tcap.cnf
@@ -130,7 +130,7 @@ if (!next_tvb)
%(DEFAULT_BODY)s
- dissect_tcap_TheComponent(implicit_tag, next_tvb, 0, actx, tcap_top_tree, hf_index);
+ dissect_tcap_ITU_ComponentPDU(implicit_tag, next_tvb, 0, actx, tcap_top_tree, hf_index);
/* return comp_offset+len; or return offset (will be automatically added */
@@ -199,7 +199,7 @@ if (!next_tvb)
%(DEFAULT_BODY)s
-dissect_tcap_TheComponentPDU(implicit_tag, next_tvb, 0, actx, tcap_top_tree, hf_index);
+dissect_tcap_ANSI_ComponentPDU(implicit_tag, next_tvb, 0, actx, tcap_top_tree, hf_index);
#----------------------------------------------------------------------------------------
#.FN_BODY OrigTransactionID