Skip to content

Commit 4426740

Browse files
committed
throw if smoothImpl failed
Signed-off-by: rayferric <[email protected]>
1 parent 366f596 commit 4426740

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

nav2_smoother/src/simple_smoother.cpp

+7-1
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,13 @@ bool SimpleSmoother::smooth(
110110
throw nav2_core::FailedToSmoothPath("No segments were smoothed");
111111
}
112112

113-
return success;
113+
if (!success) {
114+
throw nav2_core::FailedToSmoothPath(
115+
"Failed to smooth path either due to "
116+
"infeasible collision or iteration limit");
117+
}
118+
119+
return true;
114120
}
115121

116122
bool SimpleSmoother::smoothImpl(

0 commit comments

Comments
 (0)