From afb9f6dea8202e09c1a237d4e7d8c6ad8e1d94b8 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Thu, 30 Nov 2000 02:06:30 +0000 Subject: Clean up the handling of the RTSP payload a bit. svn path=/trunk/; revision=2716 --- packet-rtsp.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'packet-rtsp.c') diff --git a/packet-rtsp.c b/packet-rtsp.c index 9bc81276b0..4f0c09b879 100644 --- a/packet-rtsp.c +++ b/packet-rtsp.c @@ -4,7 +4,7 @@ * Jason Lango * Liberally copied from packet-http.c, by Guy Harris * - * $Id: packet-rtsp.c,v 1.27 2000/11/19 08:54:05 guy Exp $ + * $Id: packet-rtsp.c,v 1.28 2000/11/30 02:06:30 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs @@ -344,8 +344,11 @@ dissect_rtsp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) } datalen = tvb_length_remaining(tvb, offset); - if (is_sdp) { - if (datalen > 0) { + if (datalen > 0) { + /* + * There's stuff left over; process it. + */ + if (is_sdp) { tvbuff_t *new_tvb; /* @@ -361,9 +364,7 @@ dissect_rtsp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) */ new_tvb = tvb_new_subset(tvb, offset, -1, -1); call_dissector(sdp_handle, new_tvb, pinfo, tree); - } - } else { - if (datalen > 0) { + } else { proto_tree_add_text(rtsp_tree, tvb, offset, datalen, "Data (%d bytes)", datalen); } -- cgit v1.2.3