<p dir="ltr">Thanks Phil, and Yuya. I suppose the implied solution is to create the submenu via python and add it to the parent menu. We've restructured our code to avoid this situation.</p>
<div class="gmail_quote">On Apr 5, 2014 11:32 AM, "Phil Thompson" <<a href="mailto:phil@riverbankcomputing.com">phil@riverbankcomputing.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On 02-04-2014 9:11 pm, J Robert Ray wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi all, I wanted to share this small example program that will<br>
segfault.<br>
<br>
The newest PyQt I have been able to test it with PyQt 4.10 / Qt 4.8.4,<br>
so I dont know if it has been fixed already.<br>
<br>
In boils down to trying to add a new action to a submenu of a menu<br>
attached to a widget that has been deleted. Were having this problem<br>
due to some asynchronous RPC and getting results back after a user has<br>
caused the widget to go away.<br>
<br>
If anyone can try this in a newer PyQt to see if it still crashes, I<br>
would appreciate it.<br>
</blockquote>
<br>
It will always crash. The difference in behaviour is because the 'sub' menu is created by C++ and PyQt does not detect when it gets deleted.<br>
<br>
Phil<br>
______________________________<u></u>_________________<br>
PyQt mailing list <a href="mailto:PyQt@riverbankcomputing.com" target="_blank">PyQt@riverbankcomputing.com</a><br>
<a href="http://www.riverbankcomputing.com/mailman/listinfo/pyqt" target="_blank">http://www.riverbankcomputing.<u></u>com/mailman/listinfo/pyqt</a><br>
</blockquote></div>