Skip to content

temporary fix bug null pointer#5733

Merged
SteveMacenski merged 1 commit intoros-navigation:foxy-develfrom
suifengersan123:foxy-devel-5721
Dec 3, 2025
Merged

temporary fix bug null pointer#5733
SteveMacenski merged 1 commit intoros-navigation:foxy-develfrom
suifengersan123:foxy-devel-5721

Conversation

@suifengersan123
Copy link
Contributor


Basic Info

Info Please fill out this column
Ticket(s) this addresses (add tickets here #5721)
Primary OS tested on ubuntu 20.04
Robotic platform tested on N/A (detected via Asan)
Does this PR contain AI generated software? No
Was this PR description generated by AI software? No

Description of contribution in a few bullet points

I added null pointer checks in costmap_layer.cpp and layered_costmap.cpp respectively.

Description of documentation updates required from your changes

No user-facing documentation changes required (internal implementation fix)
No parameter changes or API modifications

Description of how this change was tested

AddressSanitizer validation: Compiled with -fsanitize=address and verified no SEGV errors occur


For Maintainers:

  • Check that any new parameters added are updated in docs.nav2.org
  • Check that any significant change is added to the migration guide
  • Check that any new features OR changes to existing behaviors are reflected in the tuning guide
  • Check that any new functions have Doxygen added
  • Check that any new features have test coverage
  • Check that any new plugins is added to the plugins page
  • If BT Node, Additionally: add to BT's XML index of nodes for groot, BT package's readme table, and BT library lists
  • Should this be backported to current distributions? If so, tag with backport-*.

Signed-off-by: suifengersan123 <yangabc810@gmail.com>
@suifengersan123
Copy link
Contributor Author

This bug is not only present in the foxy branch, but the logic related to this part in the main branch is the same as that in the foxy branch. If you have time, could you please take a look and let me know if this modification is acceptable?

@mergify
Copy link
Contributor

mergify bot commented Nov 28, 2025

@suifengersan123, all pull requests must be targeted towards the main development branch.
Once merged into main, it is possible to backport to @foxy-devel, but it must be in main
to have these changes reflected into new distributions.

@SteveMacenski
Copy link
Member

@suifengersan123 open against main as well and I'll merge the pair

@suifengersan123
Copy link
Contributor Author

@suifengersan123 open against main as well and I'll merge the pair

Thank you for your reply, and I open the PR(#5749).

@SteveMacenski SteveMacenski merged commit 3c70e7f into ros-navigation:foxy-devel Dec 3, 2025
2 checks passed
@suifengersan123 suifengersan123 deleted the foxy-devel-5721 branch December 4, 2025 12:52
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.

[nav2_costmap_2d]Null Pointer Dereference in Costmap Layer Initialization

2 participants