gazebosim / gz-msgs

Messages for Gazebo robot simulation.
https://gazebosim.org
Apache License 2.0
21 stars 43 forks source link

Fix memory leak in generator plugin code #404

Closed mjcarroll closed 8 months ago

mjcarroll commented 8 months ago

🦟 Bug fix

Summary

Use a managed pointer rather than a raw pointer to ensure that cleanup happens correctly.

Discovered with asan.

codecov[bot] commented 8 months ago

Codecov Report

Merging #404 (89d1040) into gz-msgs10 (edd9632) will not change coverage. Report is 1 commits behind head on gz-msgs10. The diff coverage is 100.00%.

:exclamation: Current head 89d1040 differs from pull request most recent head dae88a1. Consider uploading reports for the commit dae88a1 to get more accurate results

@@            Coverage Diff             @@
##           gz-msgs10     #404   +/-   ##
==========================================
  Coverage      97.26%   97.26%           
==========================================
  Files             27       27           
  Lines           1172     1172           
==========================================
  Hits            1140     1140           
  Misses            32       32           
Files Coverage Δ
core/generator/Generator.cc 92.64% <100.00%> (ø)