-
Notifications
You must be signed in to change notification settings - Fork 102
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
[ros2] memory not cleaned up (memory leak?) #126
Comments
@Martin-Idel-SI @Karsten1987 Is this only happening on shutdown ? |
@mikaelarguedas No, it seems to only happen at shutdown. Taking the example, I just duplicated the lines loading the plugin (here: https://github.com/bsinno/rosbag2/blob/8f1e7137e0e3dee13e9dc6b38213bfc3b62add3b/minimaldll/main.cpp#L26-30) and I still only see the one leak with the same amount of leaked memory |
Thanks @Martin-Idel-SI for confirming I suspect this is an optimization from Poco then, that knows the process is shutting down and there is no need to cleanup everything. I don't think there is much we can do on our side if that's the case |
what's happening if you put this line in a loop (let's say 10x) and load and unload the plugin everytime? |
@Martin-Idel-SI can you check if ros/class_loader#103 fixes the issue ? |
valgrind still reports lost bytes with the minimal example. |
Thanks @Karsten1987 for trying it! |
Sorry, should have mentioned it!
|
We've encountered that there is a junk of memory per loaded plugin not cleaned up.
When running a minimal example with valgrind, we see the following output:
The original issue to this: ros2/rosbag2#23
fyi @Martin-Idel-SI
The text was updated successfully, but these errors were encountered: