Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Crash]: Loading TTD save causes a crash #9680

Closed
AnrDaemon opened this issue Nov 9, 2021 · 4 comments
Closed

[Crash]: Loading TTD save causes a crash #9680

AnrDaemon opened this issue Nov 9, 2021 · 4 comments

Comments

@AnrDaemon
Copy link

@AnrDaemon AnrDaemon commented Nov 9, 2021

Version of OpenTTD

12.1.0.26020

Steps to reproduce

Simply loading a provided save causes OpenTTD to crash.

Upload crash files

crash-2021-11-09.zip

Attached is a crash log, crash dump and emergency save.
Also attached a save of Sept, 13 1953, which OpenTTD loading just fine, and a save from a day later, which crashes the game.

@glx22
Copy link
Contributor

@glx22 glx22 commented Nov 9, 2021

>	openttd.exe!GetObjectType(unsigned int t) Ligne 65	C++
 	[Cadre en ligne] openttd.exe!IsObjectType(unsigned int) Ligne 27	C++
 	openttd.exe!GetSlopePixelZ_Object(unsigned int tile, unsigned int x, unsigned int y) Ligne 425	C++
 	openttd.exe!SetAircraftPosition(Aircraft * v, int x, int y, int z) Ligne 539	C++
 	openttd.exe!AircraftLeaveHangar(Aircraft * v, Direction exit_dir) Ligne 1472	C++
 	openttd.exe!UpdateOldAircraft() Ligne 182	C++
 	openttd.exe!AfterLoadGame() Ligne 967	C++
 	openttd.exe!SaveOrLoad(const std::string & filename, SaveLoadOperation fop, DetailedFileType dft, Subdirectory sb, bool threaded) Ligne 3267	C++
 	openttd.exe!SafeLoad(const std::string & filename, SaveLoadOperation fop, DetailedFileType dft, GameMode newgm, Subdirectory lf, LoadFilter *) Ligne 941	C++
 	openttd.exe!SwitchToMode(SwitchMode new_mode) Ligne 1038	C++
 	openttd.exe!GameLoop() Ligne 1448	C++
 	openttd.exe!VideoDriver::GameLoop() Ligne 37	C++
 	openttd.exe!VideoDriver::GameThread() Ligne 46	C++
 	openttd.exe!StartNewThread::__l3::<lambda>(const char * name, void(*)(VideoDriver *) && F, VideoDriver * && <A_0>) Ligne 65	C++
 	[Code externe]	
 	openttd.exe!thread_start<unsigned int (__cdecl*)(void *),1>(void * const parameter) Ligne 97	C++
 	[Code externe]	

@glx22
Copy link
Contributor

@glx22 glx22 commented Nov 9, 2021

Oh it's a case of bad luck, there's a plane above a company headquarter right at the loading time.
image
And I think it may be some missing bits in 69a0c91 (yes 8 years ago).

Edit: After looking at the code, we're lucky it doesn't happen more often, as UpdateOldAircraft() is called before many major map array changes.

@michicc
Copy link
Member

@michicc michicc commented Nov 11, 2021

Wrong issue linking.

@AnrDaemon
Copy link
Author

@AnrDaemon AnrDaemon commented Nov 16, 2021

Thanks a ton. Eagerly awaiting new release.

TrueBrain pushed a commit to TrueBrain/OpenTTD that referenced this issue Jan 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants