aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2004-01-01 21:47:18 +0000
committerGuy Harris <guy@alum.mit.edu>2004-01-01 21:47:18 +0000
commit31cf9bfadb7e0316539146eca67ee9bf9eb603f0 (patch)
tree0f0643e2c935b3e1edc0283e18e2322082b580c0
parente2cb6b3a3b44bcab9e347e233ca6e12505fb1c65 (diff)
Don't show empty media formats.
svn path=/trunk/; revision=9514
-rw-r--r--packet-sdp.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/packet-sdp.c b/packet-sdp.c
index 0fb1d3bd97..0a8ef39d95 100644
--- a/packet-sdp.c
+++ b/packet-sdp.c
@@ -4,7 +4,7 @@
* Jason Lango <jal@netapp.com>
* Liberally copied from packet-http.c, by Guy Harris <guy@alum.mit.edu>
*
- * $Id: packet-sdp.c,v 1.40 2003/12/31 09:47:01 guy Exp $
+ * $Id: packet-sdp.c,v 1.41 2004/01/01 21:47:18 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@@ -822,7 +822,9 @@ dissect_sdp_media(tvbuff_t *tvb, proto_item *ti,
next_offset = tvb_find_guint8(tvb,offset,-1,' ');
if(next_offset == -1){
- tokenlen = -1; /* End of tvbuff */
+ tokenlen = tvb_length_remaining(tvb, offset); /* End of tvbuff */
+ if (tokenlen == 0)
+ break; /* Nothing more left */
} else {
tokenlen = next_offset - offset;
}