Re: crash in glib 2.32 relating to use of Gtk file chooser dialogs



On 3 Jun 2012, at 20:05, David Andruczyk wrote:

> I'm trying to debug a crash users are reporting with my app on glib 2.32.1  (gtk+-2.24.10-0ubuntu6) (what's is installed by default on ubuntu 12.04) gtk3.x is not possible with this app due to other conflicting requirements. The issues also occurs in an identical fashion on debian sid using glib 2.32.3 (gtk+2.24.10-1).  The app makes use of GtkFileChooserDialogs which is where the crash occurs, specifically on the second one used,  the first one called by my app, always works, the subsequent ones tends to crash
> 

Hi David,

I use gtk 2.20 / glib 2.24 on Windows and I can confirm that the same thing happens.  I've reported it myself and there are at least 2 other reports in Bugzilla (#636758 and #674269).  It tends to be exactly as you described.  The dialog box works once - but will crash if hidden and then re-displayed.  Gtk file chooser widget has the same problem IIRC.

This issue has been around for so long that I've had to assume it can't be fixed.  The only workaround seems to be not to create file choosers as persistent objects (e.g. class member objects).  Instead, store a pointer somewhere, create your file chooser each time you need it, then destroy it afterwards.  It's hugely annoying but it's the only solution that works AFAICT.

Just out of interest - are you using a theming engine (such as clearlooks).  On Windows, the problem seems to be worse when themes are being used but I don't know if that's significant or just a coincidence.

John


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