aboutsummaryrefslogtreecommitdiffstats
path: root/asn1
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2005-09-11 21:25:37 +0000
committerGuy Harris <guy@alum.mit.edu>2005-09-11 21:25:37 +0000
commit25c4bc9379996f934e7648f2ab8b8db3857439f6 (patch)
tree802a39b3b32b8079ff58c90a7a4e4be6385eb515 /asn1
parent0bb7a6e0038f5e90851c6d866d3f4d2e75903ab2 (diff)
Replace tvb_memcpy() calls that extract IPv4 addresses into a guint32,
and that extract IPv6 addresses into a "struct e_in6_addr", with tvb_get_ipv4() and tvb_get_ipv6() calls - except for some that we remove, by using proto_tree_add_item(), rather than replacing. Have epan/tvbuff.h include epan/ipv6-utils.h, to define "struct e_in6_addr" (not necessary to declare the tvbuff routines, but including it there means "struct e_in6_addr" is guaranteed to be defined before those declarations, so we don't get compiler complaints if we define it *after* those declarations). svn path=/trunk/; revision=15758
Diffstat (limited to 'asn1')
-rw-r--r--asn1/h225/h225.cnf2
-rw-r--r--asn1/h245/h245.cnf6
2 files changed, 4 insertions, 4 deletions
diff --git a/asn1/h225/h225.cnf b/asn1/h225/h225.cnf
index 8b34881265..b746a1d88e 100644
--- a/asn1/h225/h225.cnf
+++ b/asn1/h225/h225.cnf
@@ -231,7 +231,7 @@ CallIdentifier/guid guid
ipv4_address = 0;
%(DEFAULT_BODY)s
if (value_tvb)
- tvb_memcpy(value_tvb, (guint8*)&ipv4_address, 0, 4);
+ ipv4_address = tvb_get_ipv4(value_tvb, 0);
#.END
#----------------------------------------------------------------------------------------
#.FN_PARS H245TransportAddress/h245ipAddress/h245ipv4port
diff --git a/asn1/h245/h245.cnf b/asn1/h245/h245.cnf
index 1b7f77e942..d6722364ca 100644
--- a/asn1/h245/h245.cnf
+++ b/asn1/h245/h245.cnf
@@ -280,10 +280,10 @@ OpenLogicalChannel
%(DEFAULT_BODY)s
if ( media_channel )
- tvb_memcpy(value_tvb, (guint8*)&ipv4_address, 0, 4);
+ ipv4_address = tvb_get_ipv4(value_tvb, 0);
if ( media_control_channel )
- tvb_memcpy(value_tvb, (guint8*)&rtcp_ipv4_address, 0, 4);
+ rtcp_ipv4_address = tvb_get_ipv4(value_tvb, 0);
#.END
#----------------------------------------------------------------------------------------
@@ -815,4 +815,4 @@ VendorIdentification/versionNumber TYPE = FT_STRING DISPLAY = BASE_HEX STRINGS =
#----------------------------------------------------------------------------------------
#.FIELD_ATTR
AlternativeCapabilitySet/_item NAME = "alternativeCapability"
-#---------------------------------------------------------------------------------------- \ No newline at end of file
+#----------------------------------------------------------------------------------------