aboutsummaryrefslogtreecommitdiffstats
path: root/asn1
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2015-11-24 18:03:04 -0500
committerMichael Mann <mmann78@netscape.net>2015-11-25 19:21:28 +0000
commit73e58f025ef111810ae7c931a0262248106095f4 (patch)
tree881de0049e5e07b573675ef2ec400859e44943ba /asn1
parent0cd1a8506425fa379c88df941e3039ce9a1164d4 (diff)
create_dissector_handle -> new_create_dissector_handle for ASN.1 dissectors
Change-Id: I3d7a61a5ddd79b7bcbec5b9c515470848f413fd5 Reviewed-on: https://code.wireshark.org/review/12121 Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'asn1')
-rw-r--r--asn1/charging_ase/packet-charging_ase-template.c7
-rw-r--r--asn1/ldap/packet-ldap-template.c48
-rw-r--r--asn1/m3ap/packet-m3ap-template.c7
-rw-r--r--asn1/pkcs12/packet-pkcs12-template.c10
-rw-r--r--asn1/pkcs12/pkcs12.cnf4
-rw-r--r--asn1/q932/packet-q932-template.c9
-rw-r--r--asn1/qsig/packet-qsig-template.c14
-rw-r--r--asn1/sbc-ap/packet-sbc-ap-template.c7
-rw-r--r--asn1/t38/packet-t38-template.c16
9 files changed, 69 insertions, 53 deletions
diff --git a/asn1/charging_ase/packet-charging_ase-template.c b/asn1/charging_ase/packet-charging_ase-template.c
index ca71539206..14e0ee3411 100644
--- a/asn1/charging_ase/packet-charging_ase-template.c
+++ b/asn1/charging_ase/packet-charging_ase-template.c
@@ -51,8 +51,8 @@ static dissector_handle_t charging_ase_handle;
#include "packet-charging_ase-fn.c"
-static void
-dissect_charging_ase(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_charging_ase(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
proto_item *it;
proto_tree *tr;
@@ -64,6 +64,7 @@ dissect_charging_ase(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
dissect_charging_ase_ChargingMessageType_PDU(tvb , pinfo, tr, NULL);
}
+ return tvb_captured_length(tvb);
}
/* Register all the bits needed with the filtering engine */
@@ -99,6 +100,6 @@ proto_register_charging_ase(void)
void
proto_reg_handoff_charging_ase(void)
{
- charging_ase_handle = create_dissector_handle(dissect_charging_ase, proto_charging_ase);
+ charging_ase_handle = new_create_dissector_handle(dissect_charging_ase, proto_charging_ase);
}
diff --git a/asn1/ldap/packet-ldap-template.c b/asn1/ldap/packet-ldap-template.c
index 4c70543007..e85cf63e16 100644
--- a/asn1/ldap/packet-ldap-template.c
+++ b/asn1/ldap/packet-ldap-template.c
@@ -1421,7 +1421,7 @@ static int dissect_mscldap_netlogon_flags(proto_tree *parent_tree, tvbuff_t *tvb
return offset;
}
-static void dissect_NetLogon_PDU(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree)
+static int dissect_NetLogon_PDU(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, void* data _U_)
{
int old_offset, offset=0;
char str[256];
@@ -1440,7 +1440,8 @@ static void dissect_NetLogon_PDU(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tr
len=tvb_reported_length_remaining(tvb,offset);
/* check the len if it is to small return */
- if (len < 10) return;
+ if (len < 10)
+ return tvb_captured_length(tvb);
/* Type */
proto_tree_add_item(tree, hf_mscldap_netlogon_opcode, tvb, offset, 2, ENC_LITTLE_ENDIAN);
@@ -1626,6 +1627,7 @@ static void dissect_NetLogon_PDU(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tr
proto_tree_add_item(tree, hf_mscldap_netlogon_nt_token, tvb, offset, 2, ENC_LITTLE_ENDIAN);
offset += 2;
+ return tvb_captured_length(tvb);
}
@@ -1667,8 +1669,8 @@ dissect_normal_ldap_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, voi
return tvb_captured_length(tvb);
}
-static void
-dissect_ldap_oid(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree)
+static int
+dissect_ldap_oid(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, void* data _U_)
{
char *oid;
const char *oidname;
@@ -1680,7 +1682,7 @@ dissect_ldap_oid(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree)
oid=tvb_get_string_enc(wmem_packet_scope(), tvb, 0, tvb_reported_length(tvb), ENC_UTF_8|ENC_NA);
if(!oid){
- return;
+ return tvb_captured_length(tvb);
}
oidname=oid_resolved_from_string(wmem_packet_scope(), oid);
@@ -1690,6 +1692,7 @@ dissect_ldap_oid(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree)
} else {
proto_tree_add_string(tree, hf_ldap_oid, tvb, 0, tvb_captured_length(tvb), oid);
}
+ return tvb_captured_length(tvb);
}
#define LDAP_ACCESSMASK_ADS_CREATE_CHILD 0x00000001
@@ -1730,24 +1733,26 @@ struct access_mask_info ldap_access_mask_info = {
NULL /* Standard mapping table */
};
-static void
-dissect_ldap_nt_sec_desc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_ldap_nt_sec_desc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
dissect_nt_sec_desc(tvb, 0, pinfo, tree, NULL, TRUE, tvb_reported_length(tvb), &ldap_access_mask_info);
+ return tvb_captured_length(tvb);
}
-static void
-dissect_ldap_sid(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree)
+static int
+dissect_ldap_sid(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, void* data _U_)
{
char *tmpstr;
/* this octet string contains an NT SID */
dissect_nt_sid(tvb, 0, tree, "SID", &tmpstr, hf_ldap_sid);
ldapvalue_string=tmpstr;
+ return tvb_captured_length(tvb);
}
-static void
-dissect_ldap_guid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_ldap_guid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
guint8 drep[4] = { 0x10, 0x00, 0x00, 0x00}; /* fake DREP struct */
e_guid_t uuid;
@@ -1762,6 +1767,7 @@ dissect_ldap_guid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
uuid.data4[2], uuid.data4[3],
uuid.data4[4], uuid.data4[5],
uuid.data4[6], uuid.data4[7]);
+ return tvb_captured_length(tvb);
}
static int
@@ -1884,11 +1890,11 @@ this_was_not_normal_ldap:
return tvb_captured_length(tvb);
}
-static void
-dissect_mscldap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_mscldap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
dissect_ldap_pdu(tvb, pinfo, tree, TRUE);
- return;
+ return tvb_captured_length(tvb);
}
@@ -2289,7 +2295,7 @@ proto_reg_handoff_ldap(void)
dissector_add_uint("tcp.port", TCP_PORT_GLOBALCAT_LDAP, ldap_handle);
- cldap_handle = create_dissector_handle(dissect_mscldap, proto_cldap);
+ cldap_handle = new_create_dissector_handle(dissect_mscldap, proto_cldap);
dissector_add_uint("udp.port", UDP_PORT_CLDAP, cldap_handle);
gssapi_handle = find_dissector("gssapi");
@@ -2344,12 +2350,12 @@ proto_reg_handoff_ldap(void)
oid_add_from_string("LDAP_SERVER_SHUTDOWN_NOTIFY_OID","1.2.840.113556.1.4.1907");
oid_add_from_string("LDAP_SERVER_RANGE_RETRIEVAL_NOERR_OID","1.2.840.113556.1.4.1948");
- dissector_add_string("ldap.name", "netlogon", create_dissector_handle(dissect_NetLogon_PDU, proto_cldap));
- dissector_add_string("ldap.name", "objectGUID", create_dissector_handle(dissect_ldap_guid, proto_ldap));
- dissector_add_string("ldap.name", "supportedControl", create_dissector_handle(dissect_ldap_oid, proto_ldap));
- dissector_add_string("ldap.name", "supportedCapabilities", create_dissector_handle(dissect_ldap_oid, proto_ldap));
- dissector_add_string("ldap.name", "objectSid", create_dissector_handle(dissect_ldap_sid, proto_ldap));
- dissector_add_string("ldap.name", "nTSecurityDescriptor", create_dissector_handle(dissect_ldap_nt_sec_desc, proto_ldap));
+ dissector_add_string("ldap.name", "netlogon", new_create_dissector_handle(dissect_NetLogon_PDU, proto_cldap));
+ dissector_add_string("ldap.name", "objectGUID", new_create_dissector_handle(dissect_ldap_guid, proto_ldap));
+ dissector_add_string("ldap.name", "supportedControl", new_create_dissector_handle(dissect_ldap_oid, proto_ldap));
+ dissector_add_string("ldap.name", "supportedCapabilities", new_create_dissector_handle(dissect_ldap_oid, proto_ldap));
+ dissector_add_string("ldap.name", "objectSid", new_create_dissector_handle(dissect_ldap_sid, proto_ldap));
+ dissector_add_string("ldap.name", "nTSecurityDescriptor", new_create_dissector_handle(dissect_ldap_nt_sec_desc, proto_ldap));
#include "packet-ldap-dis-tab.c"
diff --git a/asn1/m3ap/packet-m3ap-template.c b/asn1/m3ap/packet-m3ap-template.c
index d17d4b1db4..a69d3179a7 100644
--- a/asn1/m3ap/packet-m3ap-template.c
+++ b/asn1/m3ap/packet-m3ap-template.c
@@ -116,8 +116,8 @@ static int dissect_UnsuccessfulOutcomeValue(tvbuff_t *tvb, packet_info *pinfo, p
}
-static void
-dissect_m3ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_m3ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
proto_item *m3ap_item = NULL;
proto_tree *m3ap_tree = NULL;
@@ -132,6 +132,7 @@ dissect_m3ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
dissect_M3AP_PDU_PDU(tvb, pinfo, m3ap_tree, NULL);
}
+ return tvb_captured_length(tvb);
}
/*--- proto_register_m3ap -------------------------------------------*/
void proto_register_m3ap(void) {
@@ -182,7 +183,7 @@ proto_reg_handoff_m3ap(void)
static guint SctpPort;
if( !inited ) {
- m3ap_handle = create_dissector_handle(dissect_m3ap, proto_m3ap);
+ m3ap_handle = new_create_dissector_handle(dissect_m3ap, proto_m3ap);
dissector_add_uint("sctp.ppi", PROTO_3GPP_M3AP_PROTOCOL_ID, m3ap_handle);
inited = TRUE;
#include "packet-m3ap-dis-tab.c"
diff --git a/asn1/pkcs12/packet-pkcs12-template.c b/asn1/pkcs12/packet-pkcs12-template.c
index 8be1913020..3dd6e03f04 100644
--- a/asn1/pkcs12/packet-pkcs12-template.c
+++ b/asn1/pkcs12/packet-pkcs12-template.c
@@ -68,8 +68,8 @@ static tvbuff_t *salt = NULL;
static const char *password = NULL;
static gboolean try_null_password = FALSE;
-static void dissect_AuthenticatedSafe_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);
-static void dissect_SafeContents_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);
+static int dissect_AuthenticatedSafe_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data);
+static int dissect_SafeContents_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data);
static int dissect_PrivateKeyInfo_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data);
#include "packet-pkcs12-hf.c"
@@ -407,7 +407,7 @@ static int strip_octet_string(tvbuff_t *tvb)
}
-static void dissect_AuthenticatedSafe_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
+static int dissect_AuthenticatedSafe_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_) {
int offset = 0;
asn1_ctx_t asn1_ctx;
asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
@@ -416,9 +416,10 @@ static void dissect_AuthenticatedSafe_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info
dissect_pkcs12_AuthenticatedSafe(FALSE, tvb, offset, &asn1_ctx, tree, hf_pkcs12_AuthenticatedSafe_PDU);
else
proto_tree_add_expert(tree, pinfo, &ei_pkcs12_octet_string_expected, tvb, 0, 1);
+ return tvb_captured_length(tvb);
}
-static void dissect_SafeContents_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int dissect_SafeContents_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
int offset = 0;
asn1_ctx_t asn1_ctx;
@@ -427,6 +428,7 @@ static void dissect_SafeContents_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pin
offset = strip_octet_string(tvb);
dissect_pkcs12_SafeContents(FALSE, tvb, offset, &asn1_ctx, tree, hf_pkcs12_SafeContents_PDU);
+ return tvb_captured_length(tvb);
}
static int dissect_X509Certificate_OCTETSTRING_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
diff --git a/asn1/pkcs12/pkcs12.cnf b/asn1/pkcs12/pkcs12.cnf
index 69fa46baa4..7190ff84b9 100644
--- a/asn1/pkcs12/pkcs12.cnf
+++ b/asn1/pkcs12/pkcs12.cnf
@@ -59,7 +59,7 @@ PrivateKeyInfo
/* we change the CMS id-data dissector to dissect as AuthenticatedSafe
not sure why PKCS#12 couldn't have used its own content type OID for AuthenticatedSafe */
- dissector_handle=create_dissector_handle(dissect_AuthenticatedSafe_OCTETSTRING_PDU, proto_pkcs12);
+ dissector_handle=new_create_dissector_handle(dissect_AuthenticatedSafe_OCTETSTRING_PDU, proto_pkcs12);
dissector_change_string("ber.oid", "1.2.840.113549.1.7.1", dissector_handle);
%(DEFAULT_BODY)s
@@ -71,7 +71,7 @@ PrivateKeyInfo
dissector_handle_t dissector_handle;
/* we change the CMS id-data dissector to dissect as SafeContents */
- dissector_handle=create_dissector_handle(dissect_SafeContents_OCTETSTRING_PDU, proto_pkcs12);
+ dissector_handle=new_create_dissector_handle(dissect_SafeContents_OCTETSTRING_PDU, proto_pkcs12);
dissector_change_string("ber.oid", "1.2.840.113549.1.7.1", dissector_handle);
%(DEFAULT_BODY)s
diff --git a/asn1/q932/packet-q932-template.c b/asn1/q932/packet-q932-template.c
index 55bc31c08d..74cf8b4594 100644
--- a/asn1/q932/packet-q932-template.c
+++ b/asn1/q932/packet-q932-template.c
@@ -243,8 +243,8 @@ dissect_q932_ni_ie(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tr
}
/*--- dissect_q932_ie -------------------------------------------------------*/
-static void
-dissect_q932_ie(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
+static int
+dissect_q932_ie(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_) {
gint offset;
proto_item *ti;
proto_tree *ie_tree;
@@ -265,7 +265,7 @@ dissect_q932_ie(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
proto_tree_add_item(ie_tree, hf_q932_ie_len, tvb, offset + 1, 1, ENC_BIG_ENDIAN);
offset += 2;
if (tvb_reported_length_remaining(tvb, offset) <= 0)
- return;
+ return offset;
switch (ie_type) {
case Q932_IE_FACILITY :
dissect_q932_facility_ie(tvb, offset, pinfo, ie_tree, ie_len);
@@ -278,6 +278,7 @@ dissect_q932_ie(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
proto_tree_add_item(ie_tree, hf_q932_ie_data, tvb, offset, ie_len, ENC_NA);
}
}
+ return tvb_captured_length(tvb);
}
/*--- dissect_q932_apdu -----------------------------------------------------*/
@@ -372,7 +373,7 @@ void proto_reg_handoff_q932(void) {
static gboolean q931_prefs_initialized = FALSE;
if (!q931_prefs_initialized) {
- q932_ie_handle = create_dissector_handle(dissect_q932_ie, proto_q932);
+ q932_ie_handle = new_create_dissector_handle(dissect_q932_ie, proto_q932);
/* Facility */
dissector_add_uint("q931.ie", (0x00 << 8) | Q932_IE_FACILITY, q932_ie_handle);
/* Notification indicator */
diff --git a/asn1/qsig/packet-qsig-template.c b/asn1/qsig/packet-qsig-template.c
index 9835d417f1..a3b216b89c 100644
--- a/asn1/qsig/packet-qsig-template.c
+++ b/asn1/qsig/packet-qsig-template.c
@@ -590,14 +590,16 @@ dissect_qsig_ie(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int codeset
}
}
/*--- dissect_qsig_ie_cs4 ---------------------------------------------------*/
-static void
-dissect_qsig_ie_cs4(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
+static int
+dissect_qsig_ie_cs4(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_) {
dissect_qsig_ie(tvb, pinfo, tree, 4);
+ return tvb_captured_length(tvb);
}
/*--- dissect_qsig_ie_cs5 ---------------------------------------------------*/
-static void
-dissect_qsig_ie_cs5(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
+static int
+dissect_qsig_ie_cs5(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_) {
dissect_qsig_ie(tvb, pinfo, tree, 5);
+ return tvb_captured_length(tvb);
}
/*--- qsig_init_tables ---------------------------------------------------------*/
@@ -728,11 +730,11 @@ void proto_reg_handoff_qsig(void) {
dissector_add_uint("q932.ros.local.err", qsig_err_tab[i].errcode, qsig_err_handle);
}
- qsig_ie_handle = create_dissector_handle(dissect_qsig_ie_cs4, proto_qsig);
+ qsig_ie_handle = new_create_dissector_handle(dissect_qsig_ie_cs4, proto_qsig);
/* QSIG-TC - Transit counter */
dissector_add_uint("q931.ie", CS4 | QSIG_IE_TRANSIT_COUNTER, qsig_ie_handle);
- qsig_ie_handle = create_dissector_handle(dissect_qsig_ie_cs5, proto_qsig);
+ qsig_ie_handle = new_create_dissector_handle(dissect_qsig_ie_cs5, proto_qsig);
/* SSIG-BC - Party category */
dissector_add_uint("q931.ie", CS5 | QSIG_IE_PARTY_CATEGORY, qsig_ie_handle);
diff --git a/asn1/sbc-ap/packet-sbc-ap-template.c b/asn1/sbc-ap/packet-sbc-ap-template.c
index 78fd676bfd..6ee66d0762 100644
--- a/asn1/sbc-ap/packet-sbc-ap-template.c
+++ b/asn1/sbc-ap/packet-sbc-ap-template.c
@@ -123,8 +123,8 @@ static int dissect_UnsuccessfulOutcomeValue(tvbuff_t *tvb, packet_info *pinfo, p
}
-static void
-dissect_sbc_ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_sbc_ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
proto_item *sbc_ap_item = NULL;
proto_tree *sbc_ap_tree = NULL;
@@ -139,6 +139,7 @@ dissect_sbc_ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
dissect_SBC_AP_PDU_PDU(tvb, pinfo, sbc_ap_tree, NULL);
}
+ return tvb_captured_length(tvb);
}
/*--- proto_register_sbc_ap -------------------------------------------*/
void proto_register_sbc_ap(void) {
@@ -182,7 +183,7 @@ proto_reg_handoff_sbc_ap(void)
static guint SctpPort;
if( !inited ) {
- sbc_ap_handle = create_dissector_handle(dissect_sbc_ap, proto_sbc_ap);
+ sbc_ap_handle = new_create_dissector_handle(dissect_sbc_ap, proto_sbc_ap);
dissector_add_uint("sctp.ppi", SBC_AP_PAYLOAD_PROTOCOL_ID, sbc_ap_handle);
inited = TRUE;
#include "packet-sbc-ap-dis-tab.c"
diff --git a/asn1/t38/packet-t38-template.c b/asn1/t38/packet-t38-template.c
index 7cb819bfe7..a28ea3c512 100644
--- a/asn1/t38/packet-t38-template.c
+++ b/asn1/t38/packet-t38-template.c
@@ -550,8 +550,8 @@ dissect_t38_udp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data
return tvb_captured_length(tvb);
}
-static void
-dissect_t38_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_t38_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
proto_item *it;
proto_tree *tr;
@@ -598,10 +598,11 @@ dissect_t38_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
}
}
+ return tvb_captured_length(tvb);
}
-static void
-dissect_t38_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_t38_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
primary_part = TRUE;
@@ -609,11 +610,12 @@ dissect_t38_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
dissect_tpkt_encap(tvb,pinfo,tree,t38_tpkt_reassembly,t38_tcp_pdu_handle);
}
else if((t38_tpkt_usage == T38_TPKT_NEVER) || (is_tpkt(tvb,1) == -1)){
- dissect_t38_tcp_pdu(tvb, pinfo, tree);
+ dissect_t38_tcp_pdu(tvb, pinfo, tree, data);
}
else {
dissect_tpkt_encap(tvb,pinfo,tree,t38_tpkt_reassembly,t38_tcp_pdu_handle);
}
+ return tvb_captured_length(tvb);
}
/* Look for conversation info and display any setup info found */
@@ -777,8 +779,8 @@ proto_reg_handoff_t38(void)
if (!t38_prefs_initialized) {
t38_udp_handle=new_create_dissector_handle(dissect_t38_udp, proto_t38);
- t38_tcp_handle=create_dissector_handle(dissect_t38_tcp, proto_t38);
- t38_tcp_pdu_handle=create_dissector_handle(dissect_t38_tcp_pdu, proto_t38);
+ t38_tcp_handle=new_create_dissector_handle(dissect_t38_tcp, proto_t38);
+ t38_tcp_pdu_handle=new_create_dissector_handle(dissect_t38_tcp_pdu, proto_t38);
rtp_handle = find_dissector("rtp");
t30_hdlc_handle = find_dissector("t30.hdlc");
data_handle = find_dissector("data");