This shouldn't be crashing the C++ node in either case.  I just tried reproducing this without any luck, both against the latest cturtle debs and ROS trunk.<div><br></div><div>I'm guessing this is related to <a href="https://code.ros.org/trac/ros-pkg/ticket/4461" target="_blank">https://code.ros.org/trac/ros-pkg/ticket/4461</a>, which I've also so far been unable to reproduce.</div>

<div><br></div><div>What version of ROS are you running, on what OS?</div>
<div><br></div><div>Josh<br><br><div class="gmail_quote">On Tue, Oct 12, 2010 at 5:41 AM, Ugo Cupcic <span dir="ltr"><<a href="mailto:ugo@shadowrobot.com" target="_blank">ugo@shadowrobot.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


 Hey,<br>
<br>
I found the problem. If you overload the __del__(self) function in your<br>
class, then something bad happens when closing the node...<br>
<br>
Cheers,<br>
<font color="#888888"><br>
Ugo<br>
</font><div><div></div><div><br>
On 12/10/10 12:02, Ugo Cupcic wrote:<br>
>  Hi all,<br>
><br>
> I have a really weird behaviour in rospy.<br>
> If I create a publisher to an existing topic of a custom C++ node, run<br>
> rospy.spin in a separate node, then do nothing and close the python<br>
> node, the C++ node crashes:<br>
> [shadowhand-5] process has died [pid 5903, exit code -11].<br>
><br>
> The simple code in python can be found here:<br>
> <a href="http://pastebin.com/xwZiKn3R" target="_blank">http://pastebin.com/xwZiKn3R</a><br>
><br>
> If I replace the publisher by a subscriber then my C++ node doesn't<br>
> crash. What's really weird is that my C++ node seems to be pretty stable<br>
> (I often kept it running for one day without any trouble). When I run<br>
> the C++ node in gdb then it doesn't crash...<br>
><br>
> Is there a call made to the node when a publisher to this node is deleted?<br>
><br>
> Any help greatly appreciated.<br>
><br>
> Cheers,<br>
><br>
> Ugo<br>
><br>
<br>
--<br>
Ugo Cupcic         |  Shadow Robot Company | <a href="mailto:ugo@shadowrobot.com" target="_blank">ugo@shadowrobot.com</a><br>
Software Engineer  |    251 Liverpool Road |<br>
need a Hand?       |    London  N1 1LX     | +44 20 7700 2487<br>
<a href="http://www.shadowrobot.com/hand/" target="_blank">http://www.shadowrobot.com/hand/</a>              @shadowrobot<br>
<br>
_______________________________________________<br>
ros-users mailing list<br>
<a href="mailto:ros-users@code.ros.org" target="_blank">ros-users@code.ros.org</a><br>
<a href="https://code.ros.org/mailman/listinfo/ros-users" target="_blank">https://code.ros.org/mailman/listinfo/ros-users</a><br>
</div></div></blockquote></div><br></div>