[yast-devel] Python-yui's TreeItem widget causes segfault
Hi, My program works for most other widgets included, but when I use the TreeItem, I get a Segfault at the end of my program. The program otherwise works as desired. Do you have any suggestions to fix this? Even just this code causes this problem: item1 = yui.YTreeItem("hello") item2 = yui.YTreeItem(item1, "world") I am using Python 2.6 on Sles 11.0. Pranav -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
Hi Pranav,
My program works for most other widgets included, but when I use the TreeItem, I get a Segfault at the end of my program. The program otherwise works as desired. Do you have any suggestions to fix this?
Even just this code causes this problem: item1 = yui.YTreeItem("hello") item2 = yui.YTreeItem(item1, "world")
I am using Python 2.6 on Sles 11.0.
Erm, looks similar to https://bugzilla.novell.com/show_bug.cgi?id=427372 which has been fixed, but no clue if the fix went to SLES11 (is this GA or SP1?). Please check the changelog of yast2-libyui package I've tried myself (not really proficient in python, though) with fixed libyui and i) I can get a simple dialog with 1 tree widget and 1 button displayed, but only in text-mode/ncurses (wut? :) ), GUI just shows an empty box ii) it always segfaults on closing the dialog The bug quoted above deals with memory ownership issues, so it seems to me there are still some places left where this needs to be addressed in libyui(- bindings). Conclusion: please file a bug, assign to yast2-maintainers and CC: kkaempf. Don't forget to include a code sample B. P.S. Here's my lame code: import sys sys.path.insert(0,'../../../build/bindings/python') import yui log = yui.YUILog.instance() log.enableDebugLogging( True ) factory = yui.YUI.widgetFactory() dialog = factory.createPopupDialog() item1 = yui.YTreeItem("hello") item2 = yui.YTreeItem( item1, "world") vbox = factory.createVBox( dialog ) tree = factory.createTree( vbox, "Hello, World!" ) tree.addItem(item1) factory.createPushButton( vbox, "&OK" ) event = dialog.waitForEvent() dialog.destroy() -- \\\\\ Katarina Machalkova \\\\\\\__o OOo developer __\\\\\\\'/_ & hedgehog painter
On Fri, Jun 25, 2010 at 11:17:13AM +0200, Bubli wrote:
Erm, looks similar to https://bugzilla.novell.com/show_bug.cgi?id=427372 which has been fixed, but no clue if the fix went to SLES11 (is this GA or SP1?). Please check the changelog of yast2-libyui package
I have checked, and the fix(*) is not in SLE11 GA. *) http://svn.opensuse.org/viewcvs/yast?rev=54641&view=rev
I've tried myself (not really proficient in python, though) with fixed libyui and
i) I can get a simple dialog with 1 tree widget and 1 button displayed, but only in text-mode/ncurses (wut? :) ), GUI just shows an empty box ii) it always segfaults on closing the dialog
Anyway, I could reproduce (i) and (ii) even on openSUSE 11.2 which has the fix. -- Martin Vidner, YaST developer http://en.opensuse.org/User:Mvidner Kuracke oddeleni v restauraci je jako fekalni oddeleni v bazenu
* Martin Vidner
On Fri, Jun 25, 2010 at 11:17:13AM +0200, Bubli wrote:
Erm, looks similar to https://bugzilla.novell.com/show_bug.cgi?id=427372 which has been fixed, but no clue if the fix went to SLES11 (is this GA or SP1?). Please check the changelog of yast2-libyui package
I have checked, and the fix(*) is not in SLE11 GA. *) http://svn.opensuse.org/viewcvs/yast?rev=54641&view=rev
I've tried myself (not really proficient in python, though) with fixed libyui and
i) I can get a simple dialog with 1 tree widget and 1 button displayed, but only in text-mode/ncurses (wut? :) ), GUI just shows an empty box ii) it always segfaults on closing the dialog
Thanks Bubli for the analysis. This is most probably a dangling pointer issue which we have plenty in the libyui(-bindings) :-/ A bug report and sample code is greatly appreciated ;-) Klaus --- SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
This is most probably a dangling pointer issue which we have plenty in the libyui(-bindings) :-/
A bug report and sample code is greatly appreciated ;-)
Thanks guys, I've filed a bug report mentioning your ideas. Pranav -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
participants (4)
-
Katarina Machalkova
-
Klaus Kaempf
-
Martin Vidner
-
Pranav Senthilnathan