aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--AUTHORS4
-rw-r--r--doc/ethereal.pod.template1
-rw-r--r--packet-rtcp.c26
3 files changed, 19 insertions, 12 deletions
diff --git a/AUTHORS b/AUTHORS
index c4aa62c3c0..5935043752 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -987,6 +987,10 @@ Dinesh Dutt <ddutt[AT]cisco.com> {
SCSI dissector, for use by iSCSI and other protocols that
transport SCSI operations
}
+
+Nagarjuna Venna <nvenna[AT]Brixnet.com> {
+ Only display the reason in BYE RTCP packets if it's present
+}
Alain Magloire <alainm[AT]rcsm.ece.mcgill.ca> was kind enough to
give his permission to use his version of snprintf.c.
diff --git a/doc/ethereal.pod.template b/doc/ethereal.pod.template
index d051eae9ce..cdedd603ff 100644
--- a/doc/ethereal.pod.template
+++ b/doc/ethereal.pod.template
@@ -1278,6 +1278,7 @@ B<http://www.ethereal.com>.
Irfan Khan <ikhan[AT]qualcomm.com>
Jayaram V.R <vjayar[AT]cisco.com>
Dinesh Dutt <ddutt[AT]cisco.com>
+ Nagarjuna Venna <nvenna[AT]Brixnet.com>
Alain Magloire <alainm[AT]rcsm.ece.mcgill.ca> was kind enough to give his
permission to use his version of snprintf.c.
diff --git a/packet-rtcp.c b/packet-rtcp.c
index 1f8770e452..9062fb4ab4 100644
--- a/packet-rtcp.c
+++ b/packet-rtcp.c
@@ -1,6 +1,6 @@
/* packet-rtcp.c
*
- * $Id: packet-rtcp.c,v 1.27 2001/12/10 00:25:33 guy Exp $
+ * $Id: packet-rtcp.c,v 1.28 2002/01/10 22:21:13 guy Exp $
*
* Routines for RTCP dissection
* RTCP = Real-time Transport Control Protocol
@@ -386,18 +386,20 @@ dissect_rtcp_bye( tvbuff_t *tvb, int offset, frame_data *fd, proto_tree *tree,
offset += 4;
}
- /* Bye reason consists of an 8 bit length l and a string with length l */
- reason_length = tvb_get_guint8( tvb, offset );
- proto_tree_add_item( tree, hf_rtcp_ssrc_length, tvb, offset, 1, FALSE );
- offset++;
+ if ( tvb_reported_length_remaining( tvb, offset ) > 0 ) {
+ /* Bye reason consists of an 8 bit length l and a string with length l */
+ reason_length = tvb_get_guint8( tvb, offset );
+ proto_tree_add_item( tree, hf_rtcp_ssrc_length, tvb, offset, 1, FALSE );
+ offset++;
- reason_text = ( char* ) malloc( reason_length + 1 );
- for ( counter = 0; counter < reason_length; counter++ ) reason_text[ counter ] = tvb_get_guint8( tvb, offset + counter );
- /* strncpy( reason_text, pd + offset, reason_length ); */
- reason_text[ reason_length ] = '\0';
- proto_tree_add_string( tree, hf_rtcp_ssrc_text, tvb, offset, reason_length, reason_text );
- free( reason_text );
- offset += reason_length;
+ reason_text = ( char* ) malloc( reason_length + 1 );
+ for ( counter = 0; counter < reason_length; counter++ ) reason_text[ counter ] = tvb_get_guint8( tvb, offset + counter );
+ /* strncpy( reason_text, pd + offset, reason_length ); */
+ reason_text[ reason_length ] = '\0';
+ proto_tree_add_string( tree, hf_rtcp_ssrc_text, tvb, offset, reason_length, reason_text );
+ free( reason_text );
+ offset += reason_length;
+ }
return offset;