aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeff Morriss <jeff.morriss@ulticom.com>2011-02-10 22:14:05 +0000
committerJeff Morriss <jeff.morriss@ulticom.com>2011-02-10 22:14:05 +0000
commitb1d4ef88516f250106728d0b8deb713d6276db09 (patch)
tree54ac2f4f7961529695622d4ac5beae3b5e0d5266
parentb58b5b5c677b6ac8820fa50e1d6685b14700922d (diff)
Use tvb_ip_to_str() and tvb_ether_to_str().
svn path=/trunk/; revision=35905
-rw-r--r--epan/dissectors/packet-rsip.c18
-rw-r--r--epan/dissectors/packet-rsvp.c2
2 files changed, 9 insertions, 11 deletions
diff --git a/epan/dissectors/packet-rsip.c b/epan/dissectors/packet-rsip.c
index 8b2965b149..2ae4577c9b 100644
--- a/epan/dissectors/packet-rsip.c
+++ b/epan/dissectors/packet-rsip.c
@@ -14,12 +14,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -303,8 +303,7 @@ rsip_parameter(tvbuff_t *tvb, proto_tree *rsip_tree, int off, int eoff)
hf_rsip_parameter_address_ipv4, tvb,
off + 4, paramlen - 1, FALSE);
proto_item_append_text(pti, ": %s",
- ip_to_str(tvb_get_ptr(tvb, off + 4,
- paramlen - 1)));
+ tvb_ip_to_str(tvb, off + 4));
} else
proto_item_append_text(pti,
": Any IPv4 Address");
@@ -315,8 +314,7 @@ rsip_parameter(tvbuff_t *tvb, proto_tree *rsip_tree, int off, int eoff)
hf_rsip_parameter_address_ipv4_netmask,
tvb, off + 4, paramlen - 1, FALSE);
proto_item_append_text(pti, "(netmask): %s",
- ip_to_str(tvb_get_ptr(tvb, off + 4,
- paramlen - 1)));
+ tvb_ip_to_str(tvb, off + 4));
} else
proto_item_append_text(pti,
": Any IPv4 Netmask");
@@ -1078,12 +1076,12 @@ dissect_rsip(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* Register the protocol with Wireshark */
void
proto_register_rsip(void)
-{
+{
static hf_register_info hf[] = {
{ &hf_rsip_version,
{ "Protocol version", "rsip.version",
- FT_UINT8, BASE_DEC, NULL, 0x0,
+ FT_UINT8, BASE_DEC, NULL, 0x0,
NULL, HFILL }
},
{ &hf_rsip_message_type,
@@ -1255,14 +1253,14 @@ proto_reg_handoff_rsip(void)
{
static gboolean initialized = FALSE;
dissector_handle_t rsip_handle;
-
+
if (!initialized) {
rsip_handle = create_dissector_handle(dissect_rsip,
proto_rsip);
dissector_add_uint("udp.port", UDP_PORT_RSIP, rsip_handle);
dissector_add_uint("tcp.port", TCP_PORT_RSIP, rsip_handle);
-
+
initialized = TRUE;
}
}
diff --git a/epan/dissectors/packet-rsvp.c b/epan/dissectors/packet-rsvp.c
index 54cca7c8f9..5b65584331 100644
--- a/epan/dissectors/packet-rsvp.c
+++ b/epan/dissectors/packet-rsvp.c
@@ -5707,7 +5707,7 @@ dissect_rsvp_call_id (proto_tree *ti, proto_tree *rsvp_object_tree,
case 4:
offset4 = offset3 + 6;
- str = ether_to_str(tvb_get_ptr(tvb, offset3, 6));
+ str = tvb_ether_to_str(tvb, offset3);
proto_tree_add_text(rsvp_object_tree, tvb, offset3, 6,
"Source Transport Network addr: %s", str);
break;