diff options
author | AndersBroman <anders.broman@ericsson.com> | 2014-05-05 17:37:12 +0200 |
---|---|---|
committer | Anders Broman <a.broman58@gmail.com> | 2014-05-05 15:51:18 +0000 |
commit | 09a9c86473645e33383df65c8b6986a542ba4e2d (patch) | |
tree | 24bd49db02d3a37e254b0e0e643417d84c2c94b6 /asn1/h248/h248.cnf | |
parent | 326202f016ca1ca158b7ca8bcfa79187eafb9d0f (diff) |
Add the possibillity to add a string to the termination id.
Change-Id: I3b48b28273a8c1a1558045d2a4ab5104160840de
Reviewed-on: https://code.wireshark.org/review/1510
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'asn1/h248/h248.cnf')
-rw-r--r-- | asn1/h248/h248.cnf | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/asn1/h248/h248.cnf b/asn1/h248/h248.cnf index ee1afdb022..5c1ade583b 100644 --- a/asn1/h248/h248.cnf +++ b/asn1/h248/h248.cnf @@ -330,23 +330,36 @@ AuditReplyV1/auditResult audit_result #.FN_BODY TerminationID/id tvbuff_t* new_tvb; + h248_term_info_t term_info; + + term_info.wild_card = wild_card; + term_info.str = NULL; + offset = dissect_ber_octet_string(implicit_tag, actx, tree, tvb, offset, hf_index, &new_tvb); if (new_tvb) { curr_info.term->len = tvb_length(new_tvb); curr_info.term->type = 0; /* unknown */ + if (h248_term_handle) { + call_dissector_with_data(h248_term_handle, new_tvb, actx->pinfo, tree, &term_info); + wild_card = 0xFF; + } + if (curr_info.term->len) { curr_info.term->buffer = (guint8 *)tvb_memdup(wmem_packet_scope(),new_tvb,0,curr_info.term->len); - curr_info.term->str = bytes_to_ep_str(curr_info.term->buffer,curr_info.term->len); + if(term_info.str){ + curr_info.term->str = wmem_strdup_printf(wmem_packet_scope(), "%s %s", + bytestring_to_str(wmem_packet_scope(),curr_info.term->buffer,curr_info.term->len, 0), + term_info.str); + }else{ + curr_info.term->str = bytestring_to_str(wmem_packet_scope(),curr_info.term->buffer,curr_info.term->len, 0); + } } + curr_info.term = gcp_cmd_add_term(curr_info.msg, curr_info.trx, curr_info.cmd, curr_info.term, wild_term, keep_persistent_data); - if (h248_term_handle) { - call_dissector_with_data(h248_term_handle, new_tvb, actx->pinfo, tree, &wild_card); - wild_card = 0xFF; - } } else { curr_info.term->len = 0; curr_info.term->buffer = (guint8*)wmem_strdup(wmem_packet_scope(), ""); |