Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix skeleton data destroy cause a memory leak #4307

Closed
wants to merge 1 commit into from

Conversation

zhakesi
Copy link
Contributor

@zhakesi zhakesi commented Mar 7, 2023

No description provided.

}
}
info->release();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why remove retain & release code ?

@dumganhar
Copy link
Contributor

@PatriceJiang Please review this change.

@PatriceJiang
Copy link
Contributor

It seems that the memory leak is caused by the mismatch between the calls of retainByUUID and releaseByUUID. The current fix requires addressing a potential issue: releasing the SkeletonData, which is held by multiple places, prematurely leading to a crash.

@Sunny-guangge
Copy link

这个合并并不能解决内存泄漏问题

@dumganhar
Copy link
Contributor

这个合并并不能解决内存泄漏问题

@Sunny-guangge How to reproduce the leak you found?

@Sunny-guangge
Copy link

这个合并并不能解决内存泄漏问题

@Sunny-guangge How to reproduce the leak you found?

非常简单 加载一个spine资源 然后销毁 销毁的时候 在js skeletonDataMgr.setDestroyCallback function添加断点 是不执行这段代码的

@Sunny-guangge
Copy link

这个合并并不能解决内存泄漏问题

@Sunny-guangge How to reproduce the leak you found?

现在在iOS17beta系统上 必现崩溃

@gd-888
Copy link

gd-888 commented Dec 8, 2023

@Sunny-guangge ios17崩溃问题有解决方案没

@dumganhar
Copy link
Contributor

@bofeng-song Please check the crash issue on ios17.

@zhakesi zhakesi closed this Dec 14, 2023
@bofeng-song
Copy link
Contributor

bofeng-song commented Dec 27, 2023

这个合并并不能解决内存泄漏问题

@Sunny-guangge How to reproduce the leak you found?

现在在iOS17beta系统上 必现崩溃

最好不要参考之前的pr修改,
麻烦参考这个修改
#4336
这个本身不是内存泄漏,而是内存释放不及时
@Sunny-guangge

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants