The International Simutrans Forum

Simutrans Extended => Simutrans-Extended bug reports => Simutrans-Extended development => Simutrans-Extended closed bug reports => Topic started by: Vladki on December 13, 2016, 09:55:30 PM

Title: Crash on exit
Post by: Vladki on December 13, 2016, 09:55:30 PM
I have updated the testing server to latest exicutable and pakset. Simutrans now crashes when I want to quit the online game, with the following output:


FATAL ERROR: vector_tpl<T>::[] - 20transferring_cargo_t: index out of bounds: 0 not in 0..4294967295
Aborting program execution ...

For help with this error or to file a bug report please see the Simutrans forum at
http://forum.simutrans.com
Neúspěšně ukončen (SIGABRT)


Next start says that the savegame is corrupted, and the second start gives me the demo game. Exiting and starting form the demo game works fine.
Title: Re: Crash on exit
Post by: jamespetts on December 13, 2016, 11:49:42 PM
I am having trouble reproducing this because I get a crash deep in the networking code whenever I try to connect. This specific crash I have been told relates to a bug from Standard that only usually arises when there is a desync.

I have, however, fixed a bug related to disconnecting from network games. Can you re-test?
Title: Re: Crash on exit
Post by: Vladki on December 14, 2016, 08:41:15 PM
It is still the same. I get a desyc sometimes, (due to interference on wi-fi), but it does not crash on desync. I reconnected to wifi on different channel to get rid of desyncs, but the crash on exit is still there.
Title: Re: Crash on exit
Post by: jamespetts on December 14, 2016, 11:53:30 PM
Can you upload the saved game so that I can see whether I can isolate the problem from the crash on desync issue?
Title: Re: Crash on exit
Post by: Vladki on January 05, 2017, 10:10:23 PM
Well, when I switch to better connection, I do not get the FATAL ERROR: vector_tpl<T>::[] - 20transferring_cargo_t: index out of bounds: 0 not in 0..4294967295 on exit. However with bad connection (2.4 GHz wifi) I get that even with fresh game (server.exp.simutrans.com:13354) http://server.exp.simutrans.com/debug-saves/svenska.sve (pak128.sweden-ex)

After disconnecting from more developed game, I get one more crash on next start saying FATAL ERROR: loadsave_t::read - savegame corrupt, not enough data
. While debugging other crashes, I found out that I cannot save a server game, even with good connection - again the same error.

Edit: now I got the same error on exit even on my better connection...
Title: Re: Crash on exit
Post by: jamespetts on January 09, 2017, 10:20:09 AM
I think that I have managed to fix this; would you be able to re-test? I should be most grateful.
Title: Re: Crash on exit
Post by: Vladki on January 09, 2017, 09:40:31 PM
Seems to be OK.
Title: Re: Crash on exit
Post by: Ves on January 09, 2017, 09:51:29 PM
Are the server.exp.sim... running the latest build now?
Title: Re: Crash on exit
Post by: Vladki on January 09, 2017, 09:57:50 PM
not yet
Edit: now it is updated
Title: Re: Crash on exit
Post by: Ves on January 09, 2017, 10:05:00 PM
Remember to save the map when you update!
Title: Re: Crash on exit
Post by: Vladki on January 09, 2017, 10:11:52 PM
Quote from: Ves on January 09, 2017, 10:05:00 PM
Remember to save the map when you update!
Sorry, forgot... But there is a setting .server_save_game_on_quit = 1
hmm let's see if it works
Title: Re: Crash on exit
Post by: Ves on January 09, 2017, 10:31:35 PM
Dont worry. I was working on the map however, so suddently I got disconnected :P
Lets try that setting and see if it works!

edit
And now it does not crash when closing down either!