[Gtk-osx-users] Segmentation fault accessing widget props



Hi everyone, 

I've been looking into why my app segfaults with the latest GTK/PyGTK binaries and have whittled it down to this minimal fragment: 

import gtk
w = gtk.Window() 
w.props.visible 

This isn't limited to the gtk.Window's visible property: accessing the label property of a gtk.MenuItem breaks just as well.
Replacing the last line with w.get_property('visible') eliminates the fault.

I've reproduced this over a couple of builds on different machines but it seems so basic that I'd appreciate it if someone could confirm it for me. 

Details on versions below. 

best, 
Richard. 

Known good version:
Python is  2.5.2 (r252:60911, Jul 29 2010, 16:21:54) [GCC 4.0.1 (Apple Inc. build 5465)]
GTK  is  (2, 18, 8)
glib is  (2, 24, 1)
PyGTK Version is 	(2, 16, 0)
PyGObject Version is 	(2, 20, 0)

Fault observed under: (occurs under both the home-baked jhbuild python and system python2.5) 
Python is  2.5.2 (r252:60911, Nov 26 2010, 13:41:11) [GCC 4.0.1 (Apple Inc. build 5465)]
GTK  is  (2, 20, 1)
glib is  (2, 24, 1)
PyGTK Version is 	(2, 22, 0)
PyGObject Version is 	(2, 26, 0)

Here's a gdb session run on 10.6/intel of a 10.5 tree built on 10.5:  

>>> import gtk
[...reading symbols...]
>>> w = gtk.Window()
[...reading symbols...] 
>>> w
<gtk.Window object at 0x31e080 (GtkWindow at 0x2016010)>
>>> w.props.visible

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0xffffffff
0x00058f0b in PyTuple_Pack ()
(gdb) bt
#0  0x00058f0b in PyTuple_Pack ()
#1  0x0009d5d7 in PyEval_EvalFrameEx ()
#2  0x000a022a in PyEval_EvalCodeEx ()
#3  0x000a0337 in PyEval_EvalCode ()
#4  0x000c3d74 in PyRun_InteractiveOneFlags ()
#5  0x000c3fb3 in PyRun_InteractiveLoopFlags ()
#6  0x000c47b9 in PyRun_AnyFileExFlags ()
#7  0x000d2d68 in Py_Main ()
#8  0x00002b36 in start ()
(gdb) 

 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]