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

Segmentation Fault: xbrz::nearestNeighborScale(unsigned int const*, int, int, int, unsigned int*, int, int, int, xbrz::SliceType, int, int) #1432

Open
Donkey-Glasses opened this issue Dec 23, 2023 · 5 comments
Assignees
Labels
Confirmed Reproduced but not fixed yet Invalid Not a bug or working as intended (vanilla behavior)

Comments

@Donkey-Glasses
Copy link

Received a Segmentation Fault during AI movement in a Terror Mission. I think it was during Civilian movement, but maybe not. It tends to change quickly so its hard to be sure.

I wasn't playing all that long, so here's the entire log data.
Log Data:
[22-12-2023_17-18-52] [INFO] OpenXcom Version: 1.0 git 2023-12-03 09:59
[22-12-2023_17-18-52] [INFO] Platform: Windows
[22-12-2023_17-18-52] [INFO] Data folder is:
[22-12-2023_17-18-52] [INFO] Data search is:
[22-12-2023_17-18-52] [INFO] - C:\Users\hardw\Documents\OpenXcom
[22-12-2023_17-18-52] [INFO] - C:\Program Files (x86)\OpenXcom
[22-12-2023_17-18-52] [INFO] - C:\Program Files (x86)\OpenXcom
[22-12-2023_17-18-52] [INFO] User folder is: C:\Users\hardw\Documents\OpenXcom
[22-12-2023_17-18-52] [INFO] Config folder is: C:\Users\hardw\Documents\OpenXcom
[22-12-2023_17-18-52] [INFO] Options loaded successfully.
[22-12-2023_17-18-53] [INFO] SDL initialized successfully.
[22-12-2023_17-18-54] [INFO] SDL_mixer initialized successfully.
[22-12-2023_17-18-54] [INFO] requested file not found: openxcom.png
[22-12-2023_17-18-54] [INFO] Detected locale: C
[22-12-2023_17-18-54] [INFO] Attempting to set display to 2256x1504x8...
[22-12-2023_17-18-54] [INFO] Display set to 2256x1504x8.
[22-12-2023_17-18-54] [INFO] Loading data...
[22-12-2023_17-18-54] [INFO] Scanning standard mods in 'standard'...
[22-12-2023_17-18-54] [INFO] Scanning user mods in 'C:\Users\hardw\Documents\OpenXcom\mods'...
[22-12-2023_17-18-54] [INFO] Mapping resource files...
[22-12-2023_17-18-54] [INFO] Resources files mapped successfully.
[22-12-2023_17-18-54] [INFO] Active mods:
[22-12-2023_17-18-54] [INFO] - xcom1 v1.0
[22-12-2023_17-18-54] [INFO] - UFOextender_Gun_Melee v1.0
[22-12-2023_17-18-54] [INFO] - UFOextender_Psionic_Line_Of_Fire v1.0
[22-12-2023_17-18-54] [INFO] - UFOextender_Starting_Avalanches v1.0
[22-12-2023_17-18-54] [INFO] - XcomUtil_High_Explosive_Damage v1.0
[22-12-2023_17-18-54] [INFO] - XcomUtil_Improved_Heavy_Laser v1.0
[22-12-2023_17-18-54] [INFO] - XcomUtil_Pistol_Auto_Shot v1.0
[22-12-2023_17-18-54] [INFO] Loading rulesets...
[22-12-2023_17-18-56] [INFO] Loading fonts... Font.dat
[22-12-2023_17-18-56] [INFO] Data loaded successfully.
[22-12-2023_17-18-56] [INFO] Loading language...
[22-12-2023_17-18-56] [INFO] Language loaded successfully.
[22-12-2023_17-18-56] [INFO] OpenXcom started successfully!
[22-12-2023_17-18-56] [INFO] Using software scaling routine. For best results, try an OpenGL filter.
[22-12-2023_17-21-45] [FATAL] A fatal error has occurred: Segmentation fault. This usually indicates something missing in a mod.
[22-12-2023_17-21-45] [FATAL] 0x54f2d0 OpenXcom::CrossPlatform::stackTrace(void*)
[22-12-2023_17-21-45] [FATAL] 0x552ba0 OpenXcom::CrossPlatform::crashDump(void*, std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)
[22-12-2023_17-21-45] [FATAL] 0x40dca0 signalLogger(int)
[22-12-2023_17-21-45] [FATAL] 0x87fc60 xbrz::nearestNeighborScale(unsigned int const*, int, int, int, unsigned int*, int, int, int, xbrz::SliceType, int, int)
[22-12-2023_17-21-45] [FATAL] 0x74f920c0 UnhandledExceptionFilter
[22-12-2023_17-21-45] [FATAL] 0x770cbcc0 RtlInitializeExceptionChain
[22-12-2023_17-21-45] [FATAL] 0x770cbbf0 RtlClearBits
[22-12-2023_17-21-45] [FATAL] 0x4b0000 OpenXcom::BattlescapeGame::think()
[22-12-2023_17-21-45] [FATAL] Unfortunately, no stack trace information is available
[22-12-2023_17-21-59] [FATAL] OpenXcom has crashed: Segmentation fault. This usually indicates something missing in a mod.
More details here: C:\Users\hardw\Documents\OpenXcom\openxcom.log
If this error was unexpected, please report it to the developers.

@Donkey-Glasses
Copy link
Author

crash.zip

3 of 3 repro. Load attached save file and hit end-turn. Crash occurs on civilian movement.

@MeridianOXC MeridianOXC added the Confirmed Reproduced but not fixed yet label Dec 25, 2023
@MeridianOXC
Copy link
Member

Crashes for me too.
I needed to end turn twice.
Something with unit drawing/caching.
Crashes on unit 1000017.

@MeridianOXC
Copy link
Member

It's a corrupted save (likely saved during the alien/civilian turn).
Unit 1000017 is stuck in the middle of walking.
The game doesn't recover from this state correctly and eventually it can lead to crashes like this one.
Also for example when units are stuck in the middle of shooting, etc.

Bottomline: saves during alien/civilian turn are not supported and mostly corrupted. Crashes can be expected.

@MeridianOXC MeridianOXC added the Invalid Not a bug or working as intended (vanilla behavior) label Jan 6, 2024
@MeridianOXC MeridianOXC assigned SupSuper and unassigned Yankes Jan 6, 2024
MeridianOXC added a commit to MeridianOXC/OpenXcom that referenced this issue Jan 6, 2024
@Donkey-Glasses
Copy link
Author

I am pretty sure this is a game-generated auto-save, and the original crash with the same callstack did not involve loading a save. I certainly did not generate a save file during the non-player turn myself. Is it possible the prior non-player turn ended with a unit still in movement, causing it to crash when that still-in-movement character went to act again?

@MeridianOXC
Copy link
Member

Other option is, if you played on Ironman, and Alt+F4 or force-closed OpenXcom, this would have also created such a corrupted save.

As for the rest, I don't want to speculate, but it seems unlikely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Confirmed Reproduced but not fixed yet Invalid Not a bug or working as intended (vanilla behavior)
Projects
None yet
Development

No branches or pull requests

4 participants