ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I did find something that works! You have to configure your node launch XML to indicate that the nodelet which will call exit(x) is required. Then when it detects a failure, it will kill the entire launch file.

<node pkg....="" required="true"> ... </node>

then inside nodelet you can call "exit(err);" with some error in err. Well I did the following incase there's some other path:

ros::shutdown(); raise(SIGINT); raise(SIGABRT); exit(-1);

I really want it to exit.

I did find something that works! You have to configure your node launch XML to indicate that the nodelet which will call exit(x) is required. Then when it detects a failure, it will kill the entire launch file.

<node pkg....="" pkg.... required="true">
...
</node>

</node>

then inside nodelet you can call "exit(err);" with some error in err. Well I did the following incase there's some other path:

ros::shutdown();
raise(SIGINT);
raise(SIGABRT);
exit(-1);

exit(-1);

I really want it to exit. exit.