mirror of
https://github.com/nyanmisaka/mpp.git
synced 2025-10-09 02:50:06 +08:00
[meta]: Change assert to log on cleaning leak meta
Change-Id: I61b727efba6152b9556d663c34eac8d372203d5f Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
This commit is contained in:
@@ -109,20 +109,21 @@ MppMetaService::MppMetaService()
|
|||||||
|
|
||||||
MppMetaService::~MppMetaService()
|
MppMetaService::~MppMetaService()
|
||||||
{
|
{
|
||||||
mpp_assert(list_empty(&mlist_meta));
|
if (!list_empty(&mlist_meta)) {
|
||||||
mpp_assert(list_empty(&mlist_node));
|
|
||||||
|
|
||||||
while (!list_empty(&mlist_meta)) {
|
|
||||||
MppMetaImpl *pos, *n;
|
MppMetaImpl *pos, *n;
|
||||||
|
|
||||||
|
mpp_log_f("cleaning leaked metadata\n");
|
||||||
|
|
||||||
list_for_each_entry_safe(pos, n, &mlist_meta, MppMetaImpl, list_meta) {
|
list_for_each_entry_safe(pos, n, &mlist_meta, MppMetaImpl, list_meta) {
|
||||||
put_meta(pos);
|
put_meta(pos);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mpp_assert(list_empty(&mlist_node));
|
if (!list_empty(&mlist_node)) {
|
||||||
|
|
||||||
while (!list_empty(&mlist_node)) {
|
|
||||||
MppMetaNode *pos, *n;
|
MppMetaNode *pos, *n;
|
||||||
|
|
||||||
|
mpp_log_f("cleaning leaked metadata key-value node\n");
|
||||||
|
|
||||||
list_for_each_entry_safe(pos, n, &mlist_node, MppMetaNode, list_node) {
|
list_for_each_entry_safe(pos, n, &mlist_node, MppMetaNode, list_node) {
|
||||||
put_node(pos);
|
put_node(pos);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user