mirror of
https://github.com/nyanmisaka/mpp.git
synced 2025-10-11 20:10:18 +08:00
[mpp_buffer]: fix legacy group runtime error on mpi test
git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@780 6e48237b-75ef-9749-8fc9-41990f28c85a
This commit is contained in:
@@ -117,17 +117,23 @@ static MppBufferGroupImpl *search_group_by_id_no_lock(struct list_head *list, RK
|
||||
|
||||
MPP_RET deinit_group_no_lock(MppBufferGroupImpl *group)
|
||||
{
|
||||
MppBufferGroupImpl *legacy = mpp_buffer_legacy_group();
|
||||
|
||||
mpp_alloctor_put(&group->allocator);
|
||||
list_del_init(&group->list_group);
|
||||
mpp_free(group);
|
||||
service.group_count--;
|
||||
/* if only legacy group left dump the legacy group */
|
||||
if (service.group_count == 1) {
|
||||
MppBufferGroupImpl *legacy = mpp_buffer_legacy_group();
|
||||
if (legacy->count) {
|
||||
mpp_log("found legacy group has buffer remain, start dumping\n");
|
||||
mpp_buffer_group_dump(legacy);
|
||||
abort();
|
||||
|
||||
if (group == legacy) {
|
||||
service.mLegacyGroup = NULL;
|
||||
} else {
|
||||
/* if only legacy group left dump the legacy group */
|
||||
if (service.group_count == 1) {
|
||||
if (legacy->count) {
|
||||
mpp_log("found legacy group has buffer remain, start dumping\n");
|
||||
mpp_buffer_group_dump(legacy);
|
||||
//abort();
|
||||
}
|
||||
}
|
||||
}
|
||||
return MPP_OK;
|
||||
@@ -532,7 +538,7 @@ MppBufferService::~MppBufferService()
|
||||
if (mLegacyGroup)
|
||||
mpp_buffer_group_deinit(mLegacyGroup);
|
||||
|
||||
// then remove the reset group
|
||||
// then remove the remaining group
|
||||
if (!list_empty(&mListGroup)) {
|
||||
MppBufferGroupImpl *pos, *n;
|
||||
list_for_each_entry_safe(pos, n, &mListGroup, MppBufferGroupImpl, list_group) {
|
||||
|
Reference in New Issue
Block a user