Crashing on shipping build, but not on development build.

Prior to the 15-16th May, this problem did not exist. Even after reverting completely to the 15th, this problem is still there.

Sorry if this is the wrong place to make this post, please let me know where the best place is to post this if so. I’ve run into an issue where our game is crashing (at the same place every time) on a shipping packaged build, but not on the development packaged build. It happens just before the end of the game. I do notice in the editor that, at around the same place as the crash, it will freeze for a good 5 seconds or so. In the Output Log at this time, it lists:

LogOutputDevice: Error: === Handled ensure: === LogOutputDevice: Error: Ensure condition failed: Lhs.CurrentNum == Lhs.InitialNum [File:D:\Build++UE4\Sync\Engine\Source\Runtime\Core\Public\Containers/Array.h] [Line: 207] LogOutputDevice: Error: Array has changed during ranged-for iteration! LogOutputDevice: Error: Stack: LogOutputDevice: Error: [Callstack] 0x00007fffc5400669 UE4Editor-Engine.dll!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007fffc4567f87 UE4Editor-Engine.dll!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007fffc276e00b UE4Editor-UnrealEd.dll!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007fffc2fc5296 UE4Editor-UnrealEd.dll!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007ff61eaa7b0a UE4Editor.exe!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007ff61eaba91c UE4Editor.exe!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007ff61eaba9fa UE4Editor.exe!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007ff61eacb92c UE4Editor.exe!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007ff61eace60e UE4Editor.exe!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007ff84dee7bd4 KERNEL32.DLL!UnknownFunction ] LogOutputDevice: Error: [Callstack] 0x00007ff84e92ce51 ntdll.dll!UnknownFunction ]

In the packaged build when it crashes, it creates a minidump that, if I’m reading correctly, includes:


Unhandled exception at 0x00007FF7CF0269C8 (Faceless-Win64-Shipping.exe) in UE4Minidump.dmp: 0xC0000005: Access violation reading location 0x0000000400000000. 

(Not sure if it’s just not reading the minidump here or not.)

Any help would be extremely appreciated, our programmer is currently on a short and much-needed break. Otherwise, we may have to launch using the development build with on-screen messages disabled (and hopefully the console too).

If I can provide any more info please ask!

Thank you.

Do not modify the size of an array while iterating on it:

Thanks, Bruno, I’ll pass this onto my programmer. In the meantime, is it possible for someone like myself (with little to no experience) to investigate and hopefully resolve this?

You have to edit the piece of code that’s running that mod on the array.

The general way to take items out of an array during a loop is to run backwards through the array.