[Live-devel] Question about MultiFramedRTPSource.cpp

Pearson, Christopherx C christopherx.c.pearson at intel.com
Mon Dec 8 12:34:01 PST 2003


> Note that - three lines above this - is the statement:
>          bytesUsed = frameSize
> so, these two statements are equivalent.

In release 2003.08.07, the code is:

  unsigned frameSize = nextEnclosedFrameSize(newFramePtr, fTail -
fHead);
  bytesUsed = (frameSize > toSize) ? toSize : frameSize;
  fHead += (newFramePtr - origFramePtr) + frameSize;

So when frameSize > toSize, frameSize - toSize bytes are skipped.  I
actually tested this, both before and after my change, so I'm sure it
causing data loss.  However, perhaps this code was changed in a more
recent version.  I will update our source base (a non-trivial task), and
try again.

Thanks kindly for the help.

-- Chris Pearson

-----Original Message-----
From: live-devel-bounces at ns.live.com
[mailto:live-devel-bounces at ns.live.com] On Behalf Of Ross Finlayson
Sent: Sunday, December 07, 2003 10:18 PM
To: LIVE.COM Streaming Media - development & use
Subject: Re: [Live-devel] Question about MultiFramedRTPSource.cpp


At 10:16 PM 12/4/03, you wrote:
>It appears to me that the BufferedPacket::use() method can truncate RTP

>packets that do not fit in the caller's buffer passed to 
>getNextFrame(). Specifically, in LIVE.com release 2003.08.07,

Note that, in general, support is provided for the latest version of the

code only.  So, developers should make sure they're using the latest 
version of the code when they run into a problem.

>MultiFramedRTPSource.cpp:348 reads:
>
>   fHead += (newFramePtr - origFramePtr) + frameSize;
>
>Since only 'bytesUsed' bytes were copied to the caller's buffer, I 
>think the line should read:
>
>   fHead += (newFramePtr - origFramePtr) + bytesUsed;

Note that - three lines above this - is the statement:
         bytesUsed = frameSize
so, these two statements are equivalent.


	Ross Finlayson
	LIVE.COM
	<http://www.live.com/>

_______________________________________________
live-devel mailing list
live-devel at lists.live.com
http://lists.live.com/mailman/listinfo/live-devel



More information about the live-devel mailing list