Skip to content

内存泄漏 #26

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

Open
zjbistu opened this issue Mar 20, 2024 · 0 comments
Open

内存泄漏 #26

zjbistu opened this issue Mar 20, 2024 · 0 comments

Comments

@zjbistu
Copy link

zjbistu commented Mar 20, 2024

我在执行以下代码时,无法完全释放viewer指向的内存,每次循环大约6-8M内存泄漏,请问是调用方式有问题,还是释放方式不对。谢谢。
while(true){
pcl::visualization::PCLVisualizer::Ptr viewer(new pcl::visualization::PCLVisualizer(""));
viewer->close(); // 关闭窗口
viewer.reset(); // 显式释放
}

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

No branches or pull requests

1 participant