Ethereal-cvs: [Ethereal-cvs] cvs commit: ethereal packet-rtcp.c

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Guy Harris <guy@xxxxxxxxxxxxxxxxxxx>
Date: Sat, 18 Aug 2001 04:27:09 -0500 (CDT)
guy         2001/08/18 04:27:08 CDT

  Modified files:
    .                    packet-rtcp.c 
  Log:
  Check first whether there's any data left in the packet before checking
  whether that data is an end-marker in an SDES, so we don't report a
  malformed frame if the SDES list doesn't end with an RTCP_SDES_END
  marker (RFC 1889 says "The list of items in each chunk is terminated by
  one or more null octets, the first of which is interpreted as an item
  type of zero to denote the end of the list", but the "Parsing RTCP SDES
  packets" example doesn't seem to treat hitting the end of the frame
  before seeing an RTCP_SDES_END as an error, and at least one Quicktime
  capture I have has no RTCP_SDES_END at the end).
  
  Use "tvb_reported_length_remaining()" to do the check, so that we don't
  stop until we either hit the *real* end (rather than the capture end) of
  the packet, or throw an exception (so that a "Short Frame" indication
  shows up if the capture length was such that not all the frame was
  captured).
  
  Revision  Changes    Path
  1.19      +3 -3      ethereal/packet-rtcp.c