This is the mail archive of the
cygwin-xfree
mailing list for the Cygwin XFree86 project.
Re: gtk+ applications crash when filechooser opened
- From: Carl Michal <michal at physics dot ubc dot ca>
- To: cygwin-xfree at cygwin dot com
- Date: Fri, 13 Dec 2013 11:02:34 -0800 (PST)
- Subject: Re: gtk+ applications crash when filechooser opened
- Authentication-results: sourceware.org; auth=none
- References: <alpine dot LNX dot 2 dot 00 dot 1312122309350 dot 17740 at spider dot phas dot ubc dot ca> <52AB1A51 dot 9050906 at cornell dot edu> <20131213144744 dot GG9487 at calimero dot vinschen dot de>
- Reply-to: cygwin-xfree at cygwin dot com
On Fri, 13 Dec 2013, Corinna Vinschen wrote:
On Dec 13 09:31, Ken Brown wrote:
[This is a followup to
http://cygwin.com/ml/cygwin/2013-12/msg00255.html; see also
http://cygwin.com/ml/cygwin/2013-12/msg00146.html]
On 12/13/2013 2:12 AM, Carl Michal wrote:
I recently started trying to port a gtk program to cygwin, and have
found that my program crashes everytime it tries to open a file chooser
widget.
This doesn't happen with just my own programs, but also with gvim and
emacs-x11. Either will start up ok, but both crash as soon as File->Open
is selected.
FWIW, here's one more data point. I can confirm this behavior of
gvim and emacs-X11, but on x86 only. The File->Open dialog works
fine in both gvim and emacs-X11 on x86_64.
A crash at this point would indicate a broken value returned from
*g_private_get_impl (key). It should be a valid pthread_key_t
value but appears not to be one, for some reason.
What's interesting is that the call to open the filechooser hits this
routine (g_private_get) a few times (through g_slice_alloc). If you
don't try to step into pthread_getspecific, it crashes on the third time
it is called. The same key is returned by g_private_get_impl every time.
Trying to follow into pthread_getspecific gets really weird though. The
debugger can't see the argument at all - says it doesn't exist in the
current context. It appears that if I step into pthread_getspecific it
crashes every time.
I'm a little boggled here - there are 40 odd calls to pthread_getspecific
that occur while my program starts up, and they appear to complete
successfully, unless I try to follow with the debugger.
This is from an early call to pthread_getspecific, that wouldn't crash if
I wasn't running in the debugger:
0x6c62fe70 in pthread_getspecific ()
at /usr/src/debug/cygwin-1.7.27-2/winsup/cygwin/thread.cc:2617
2617 {
gdb)
list
2612 return 0;
2613 }
2614
2615 extern "C" void *
2616 pthread_getspecific (pthread_key_t key)
2617 {
2618 if (!pthread_key::is_good_object (&key))
2619 return NULL;
2620
2621 return (key)->get ();
(gdb) print key
No symbol "key" in current context.
(gdb) s
/netrel/src/gdb-7.6.50-4/gdb/infrun.c:1942: internal-error: resume:
Assertion `pc_in_thread_step_range (pc, tp)' failed.
A problem internal to GDB has been detected,
It crashes at line 2617 - before even getting to any of the code in the
function!
I haven't tried this on the 64 bit install, but will try to.
Carl
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ: http://x.cygwin.com/docs/faq/