I have networks/passengers/transfers selected on the minimap by default and have been experiencing regular crashes. I experimented with different combinations and sequences and tabled the results. The cause of the crash seems to be an attempt to display nodes of a nonexistent network. I have video recordings to be uploaded if necessary.
| Action | Result |
| new game -> open map | no crash |
| new game -> place stop | no crash |
| new game -> place stops | no crash |
| new game -> open map -> place stop | crash |
| new game -> place stop -> open map | crash |
| new game -> place stops -> open map | crash |
| new game -> place stops -> create mail line -> open map | crash |
| new game -> place stops -> create passenger line -> open map | no crash |
| existing game -> open map -> uncheck transfers -> uncheck networks | no crash |
| existing game -> open map -> uncheck transfers -> select mail | no crash |
| existing game -> open map -> select mail | crash |
| existing game -> open map -> uncheck networks | crash |
It's an off-by-one error in the upper bound for a loop in gui/karte.cc, which would manifest if there were halts that weren't transfers. Although I'm slightly unsure why you're penultimate case would crash. Can you test this again (and also recheck the other cases) once James has incorporated my fix?
Thank you both - I have now incorporated A. Carlotti's fix. I cannot reproduce the last crash with this fix; I should be grateful if you could re-test with to-morrow's nightly build.
QuoteI'm slightly unsure why you're penultimate case would crash.
This crash happens when there is a passenger network but no mail network. If both are present then switching doesn't cause a crash.
Quote from: freddyhayward on April 22, 2019, 10:33:48 PM
This crash happens when there is a passenger network but no mail network. If both are present then switching doesn't cause a crash.
If you can still produce that crash using the upcoming nightly build, then can you upload a save which demonstrates it?
For reference, when I fix a problem in the code, it will be incorporated into the next nightly build. This is usually compiled at around 0500-0600h GMT every day, so you will need to wait until the build from after circa 0600h on the 23rd of April 2019 to check whether this is solved - unless you are compiling yourself, of course.
My apologies if you already knew this; it is not obvious whether this is obvious.
The problem seems to have been fixed in the latest build.
Splendid, thank you for confirming.