bugFreeciv - Bugs: bug #19846, Closing unit select dialog asserts...

 
 
Show feedback again

bug #19846: Closing unit select dialog asserts or crashes

Submitted by:  Marko Lindqvist <cazfi>
Submitted on:  Sun 24 Jun 2012 08:43:57 AM UTC  
 
Category: client-gtk-3.0Severity: 5 - Blocker
Priority: 5 - NormalStatus: Fixed
Assigned to: Marko Lindqvist <cazfi>Open/Closed: Closed
Release: Operating System: None
Planned Release: 2.4.0, 2.5.0, 2.6.0

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Fri 03 May 2013 08:45:21 PM UTC, SVN revision 22824:

Fixed crash on gtk3-client unit selection dialog close with some gtk+
versions.

See bug #19846

(Browse SVN revision 22824)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Fri 03 May 2013 08:45:13 PM UTC, SVN revision 22823:

Fixed crash on gtk3-client unit selection dialog close with some gtk+
versions.

See bug #19846

(Browse SVN revision 22823)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Fri 03 May 2013 08:45:07 PM UTC, SVN revision 22822:

Fixed crash on gtk3-client unit selection dialog close with some gtk+
versions.

See bug #19846

(Browse SVN revision 22822)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Wed 01 May 2013 10:49:01 PM UTC, comment #12:

Attached patch avoids the crash. Supposedly this leaves a minor bug that cursor is sometimes not correctly changed, but I didn't notice any situation where that happened in my testing. Also, it shouldn't be happening with any gtk+ version where the code was not crashing before.

(file #17872, file #17873)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sat 27 Apr 2013 12:51:08 PM UTC, comment #11:

> (I haven't tried to track down the actual commit and what
> releases it went into).


commit 5e2c23214564f7dcc687fa8467020eeb6b9407a9
Author: John Lindgren <john.lindgren@aol.com>
Date: Wed Mar 13 02:03:45 2013 +0100

treeview: Don't emit cursor-changed in destruction

This is a workaround until we have a good idea on how we want to handle
signal disconnection before/during/after dispose and destroy vfunc
calls.

https://bugzilla.gnome.org/show_bug.cgi?id=671939

So yes, some other change had already fixed the crash problem for our crosser builds before.

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sat 27 Apr 2013 12:29:51 PM UTC, comment #10:

> Ubuntu Precise:3.4.2

FWIW, I run this and I get the assertion failures but haven't had the crash yet.
(Precise is an LTS release, so like Debian Wheezy it will be with us for a while.)

Comment #6 in January:

> Now works perfectly with my crosser build that uses gtk+-3.6.4.
> Maybe this is fixed in gtk+ 3.6?

But the note on the upstream bug about a patch being committed was in March (I haven't tried to track down the actual commit and what releases it went into).

Jacob Nevins <jtn>
Project Administrator
Wed 24 Apr 2013 12:25:29 AM UTC, comment #9:

Ubuntu and Debian historically diverge in libgtk update timing and history. Current revisions in releases:

Debian Wheezy: 3.4.2
Debian Experimental: 3.8.0
Ubuntu Oneiric: 3.2.0
Ubuntu Precise:3.4.2
Ubuntu Quantal: 3.6.0
Ubuntu Raring: 3.6.4

I don't have tooling to get release history for other distributions installed. I don't know what to do about Wheezy (would need to meet a fairly high set of criteria to get applied), but the patch in bugzilla looks small enough, focused enough, and safe enough that it could probably be released as part of Precise updates, if that meets the local need. As with the tooling, I'm less certain how to arrange this for other distributions.

Emmet Hikory <persia>
Project Member
Tue 23 Apr 2013 11:40:29 PM UTC, comment #8:

gtk+ bug is now RESOLVED FIXED. That leaves us to figure out how to live with buggy versions.
What distributions are affected? I know all too well that Debian Wheezy (to be released 4/5 May weekend) is. Probably recent Ubuntu versions are too (assuming they have inherited from Debian gtk+ version that has been frozen for a long time - once Wheezy is out we hopefully get a new version soon).

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Thu 07 Feb 2013 11:53:24 PM UTC, comment #7:

Gnome bug mentioned in comment #4 is still open, but the related gtk+ code has changed in 3.6, maybe unintentionally fixing this.

Obvious solution for us would be to make gtk+-3.6 the minimum requirement. Problem with that solution is that it would make gtk3-client unavailable to almost everyone (even not-yet-released Debian Wheezy has only 3.4, so it will be another release cycle before Debian has at least 3.6) That's not catastrophic from end-user point of view as we still have equally fully functional gtk2-client, and it will be a long time before freeciv-2.5 (with gtk3-client as default) is to be released anyway. However, it would make development work harder for now.

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sun 20 Jan 2013 02:18:36 PM UTC, comment #6:

Now works perfectly with my crosser build that uses gtk+-3.6.4. Maybe this is fixed in gtk+ 3.6?

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Mon 10 Dec 2012 11:37:01 AM UTC, comment #5:

See also bug #20224 - presumably because of newer gtk+ this is no longer mere gtk+ assert, but crashes the client.

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sat 01 Dec 2012 09:51:44 AM UTC, comment #4:

patch #3469#comment24 points to https://bugzilla.gnome.org/show_bug.cgi?id=671939

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sun 12 Aug 2012 02:04:36 AM UTC, comment #3:

Well, right now I've got the client nearly in pieces (mostly due to gridding - nearly done now, just restoring the spacing and minor tweaks left), but it seems my first comment was on the spot - due to the order of signals being undefined, instead of
fc_assert_ret(pdialog);
it should just be
if (!pdialog) return;

Though I might have broken something else (unrelated to the above fix), as "Select"/"Deselect" seems to cease to work altogether.

Rafał Mużyło <galtgendo>
Fri 29 Jun 2012 04:45:07 PM UTC, comment #2:

OK, partially wrong call in the second case - I was testing a different thing than I though I was.

It seems to only affect "Select" button.
For whatever the reason, unit_focus_update() called after USDLG_CMD_SELECT makes it not work properly.

On that note: it would likely make sense to turn the first tab of the dialog to a "pastebin" - that is to allow to select more than one unit in the dialog and put the selection into this first tab as it gets build.
Also, it would be nice if selecting a unit from that dialog wouldn't select units from the same field. As a corollary, perhaps "center" action (one called on map by "c") could cycle through the list of selected units (instead of just focusing on the first unit of the list) ?

Anonymous
Fri 29 Jun 2012 02:40:17 PM UTC, comment #1:

There's quite a bit more:
- the original problem: AFAICT, it comes down to cursor-changed callback getting run after row-activated callback, so that usdlg_get(FALSE) returns NULL, as the dialog has already been destroyed
- the second part: "Select" button of this dialog seems to work only while in first tab (I suspect other buttons to be affected too, though row-activated callback works regardless of the tab)

Assertions don't seem to happen in gtk2 client (even if the buttons still fail in the same way) - it seems that either it's a minor problem in gtk3 or treeview is simply less strict there (i.e. I've noticed (IIRC in a different project) that treeselection returned by a treeview seems to be initially NULL in gtk3, while I haven't seen checks for such case in gtk2-based code).

Anonymous
Sun 24 Jun 2012 08:43:57 AM UTC, original submission:

Closing unit select dialog is closed, either by selecting unit or by "Close" button:

1: in usdlg_cmd_cursor_changed() [client/gui-gtk-3.0/unitselect.c::1163]: assertion 'pdialog != ((void *)0)' failed.

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #17872:  Gtk3UDlgClosed.patch added by cazfi (677B - text/x-diff)
file #17873:  Gtk3UDlgClosed-S2_4.patch added by cazfi (1kB - text/x-diff)

 

Depends on the following items: None found

Items that depend on this one

Digest:
   task dependencies.

 

Carbon-Copy List
  • -unavailable- added by persia (Posted a comment)
  • -unavailable- added by galtgendo
  • -unavailable- added by jtn (Updated the item)
  • -unavailable- added by cazfi (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 12 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 03 May 2013 08:45:42 PM UTCcazfiStatusReady For Test=>Fixed
      Assigned toNone=>cazfi
      Open/ClosedOpen=>Closed
    Wed 01 May 2013 10:49:01 PM UTCcazfiAttached File-=>Added Gtk3UDlgClosed.patch, #17872
      Attached File-=>Added Gtk3UDlgClosed-S2_4.patch, #17873
      StatusNone=>Ready For Test
      Planned Release2.4.0, 2.5.0=>2.4.0, 2.5.0, 2.6.0
    Sun 21 Apr 2013 10:22:18 PM UTCcazfiSummaryClosing unit select dialog asserts=>Closing unit select dialog asserts or crashes
    Mon 10 Dec 2012 11:37:01 AM UTCcazfiSeverity3 - Normal=>5 - Blocker
      Planned Release2.4.0=>2.4.0, 2.5.0
    Sun 12 Aug 2012 02:05:34 AM UTCgaltgendoCarbon-Copy-=>Added
    Sun 24 Jun 2012 09:31:23 AM UTCjtnPlanned Release=>2.4.0
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup