video_coding: Allocating encoded buffer based on length and not size
Review URL: http://webrtc-codereview.appspot.com/318010 git-svn-id: http://webrtc.googlecode.com/svn/trunk@1163 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@@ -61,7 +61,7 @@ VCMEncodedFrame::VCMEncodedFrame(const VCMEncodedFrame& rhs)
|
|||||||
_length = 0;
|
_length = 0;
|
||||||
if (rhs._buffer != NULL)
|
if (rhs._buffer != NULL)
|
||||||
{
|
{
|
||||||
VerifyAndAllocate(rhs._size);
|
VerifyAndAllocate(rhs._length);
|
||||||
memcpy(_buffer, rhs._buffer, rhs._length);
|
memcpy(_buffer, rhs._buffer, rhs._length);
|
||||||
_length = rhs._length;
|
_length = rhs._length;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user