Project

General

Profile

Actions

Bug #1262

closed

bug in qt client function show_tileset_error()

Added by Dean Brown 11 days ago. Updated 1 day ago.

Status:
Closed
Priority:
Normal
Category:
Qt-client
Target version:
Start date:
03/22/2025
Due date:
% Done:

0%

Estimated time:

Description

3.1.4
to repro -
1 edit file share/freeciv/trident/tiles.spec by commenting out the "user.infratile"
2 start freeciv-qt
3 click on options, go to Graphics tab
4 choose Tileset (Square) -> trident
5 click Apply, app exits without showing any dialog

If instead, edit file share/freeciv/amplio2/terrain1.spec again
commenting out the "user.infratile", then when you start freeciv-qt
you immediately get the "Tileset error" dialog before the app exits.
The difference is in the first example the code path calls ask->show(),
and in the 2nd example it calls ask->exec().

gtk clients work OK for both cases.


Files

Actions #1

Updated by Marko Lindqvist 10 days ago

Attached patch is what I think to be the right thing in show_tileset_error(), though it does not save client from potentially crashing because of having only partially loaded tileset while showing the error dialog and having the client running in general.

Actions #2

Updated by Dean Brown 10 days ago

Tested that patch and it works OK for me.

I was tempted to try making a patch myself, but
1 it's been too long since I worked with QT and I don't remember it that well
2 not sure how to test all 4 combinations of fatal/!fatal and parented/not parented
Glad you did it.

Actions #3

Updated by Marko Lindqvist 1 day ago

  • Status changed from In Review to Closed
Actions

Also available in: Atom PDF