[mpp]: revert last commit for MppBuffer leak

git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@261 6e48237b-75ef-9749-8fc9-41990f28c85a
This commit is contained in:
ChenHengming
2015-09-09 23:38:57 +00:00
parent 9b02f1c33f
commit 7de8ec2794
5 changed files with 19 additions and 38 deletions

View File

@@ -208,16 +208,10 @@ MPP_RET Mpp::put_frame(MppFrame frame)
MPP_RET Mpp::get_packet(MppPacket *packet)
{
Mutex::Autolock autoLock(mPackets->mutex());
if (!mPackets->list_size()) {
*packet = NULL;
return MPP_NOK;
if (mPackets->list_size()) {
mPackets->del_at_tail(packet, sizeof(packet));
mPacketGetCount++;
}
MppPacket pkt;
mpp_packet_new(&pkt);
mPackets->del_at_tail(pkt, sizeof(MppPacketImpl));
mPacketGetCount++;
*packet = pkt;
return MPP_OK;
}