Merge pull request #66530 from timothyqiu/navobs

This commit is contained in:
Rémi Verschelde 2022-09-28 10:11:38 +02:00 committed by GitHub
commit d3662d0e23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -134,7 +134,7 @@ NavigationObstacle2D::~NavigationObstacle2D() {
}
void NavigationObstacle2D::set_navigation(Navigation2D *p_nav) {
if (navigation == p_nav) {
if (navigation == p_nav && navigation != nullptr) {
return; // Pointless
}

View File

@ -140,7 +140,7 @@ NavigationObstacle::~NavigationObstacle() {
}
void NavigationObstacle::set_navigation(Navigation *p_nav) {
if (navigation == p_nav) {
if (navigation == p_nav && navigation != nullptr) {
return; // Pointless
}