News:

Want to praise Simutrans?
Your feedback is important for us ;D.

[r10754+] SDL_QUIT is ignored most of the time

Started by ceeac, March 31, 2024, 06:20:11 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ceeac

Since r10754, closing the main window using the x button does not work most of the time while the banner window is open. Seems to work after multiple repeated attempts (usually 5+, this is variable). Control-C in the terminal to exit the program does not work most of the time either. The program receives an SDL_QUIT message from SDL, but the corresponding sys_event seems to be ignored.

prissi


ceeac

For me, the bug still happens when the pakset is loaded from the program directory. If the pakset is loaded from the user (home) directory, everything works correctly.

prissi

For me it worked with any pak location.

Since the banner window did not handle the SDL_quit event at all, the location of the pakset did not matter. Any closing of simutrans during the banner screen before the change was due to the OS closing the window on the 5th retry (at least under windows).

Do you mean, if you start without selecting the pakset manually?

Roboron

I can not reproduce after r11106. Doesn't matter how I load the pakset, closing the windows will close Simutrans. And I don't see why the pakset location should matter, the banner is always the same

ceeac

Hm, this seems to be timing dependent, not directly related to the pakset location... Looking at simwin.cc line 2182, the quit event seems to be ignored when the event is processed by win_poll_event and not during the sync_step. So, this is hopefully fixed for good in r11123.