[FIXED] Application crash
Moderator: MOD_Command
[FIXED] Application crash
Please see attached save. If you run the scenario for a few minutes (2-3) CMANO crashes. I reloaded the scenario three times after the initial crash and got a crash every time although the actual time until the crash differs slightly between tries.
Thank you.
Forgot: I am running B972.12.
Thank you.
Forgot: I am running B972.12.
- Attachments
-
- CanarysCage.zip
- (232.32 KiB) Downloaded 24 times
RE: Application crash
Welcome back!
Thanks for the report and file. Added to the list!
Mike
Thanks for the report and file. Added to the list!
Mike
RE: Application crash
also crash
screenshots and scen file
screenshots and scen file
- Attachments
-
- Laufwerk_D.zip
- (1.03 MiB) Downloaded 18 times
RE: Application crash
Thanks added to the list.
In the future please add to a separate string as the crash cause may not be the same and the dev team likes to track bug reports to make sure they get covered. Gets weird if the link back is some other bug.
Mike
In the future please add to a separate string as the crash cause may not be the same and the dev team likes to track bug reports to make sure they get covered. Gets weird if the link back is some other bug.
Mike
RE: Application crash
I'm not able to reproduce the crash in the first post. Just press Play? What time compression are you using? And side?
The second save is a crash in the Lua code due to an incorrect OnStatusChange command.
The second save is a crash in the Lua code due to an incorrect OnStatusChange command.

Developer "Command: Modern Air/Naval Operations" project!
RE: Application crash
Question to emsoy - error by the program or error by myself ??
RE: Application crash
Hi Emsoy,
Yes, just press play, Spanish side, at 1:1 compression. I just loaded the save game twice and it crashed both times after a short while but the elapsed time before the crash varies. Here are the details of the crash as reported by Windows:
Problem signature:
Problem Event Name: APPCRASH
Application Name: Command.exe
Application Version: 1.0.0.0
Application Timestamp: 5a19a6ce
Fault Module Name: lua52.DLL
Fault Module Version: 5.2.3.0
Fault Module Timestamp: 55dc8abc
Exception Code: c0000005
Exception Offset: 00019f38
OS Version: 6.1.7601.2.1.0.256.48
Locale ID: 1033
Additional Information 1: 0a9e
Additional Information 2: 0a9e372d3b4ad19135b953a78882e789
Additional Information 3: 0a9e
Additional Information 4: 0a9e372d3b4ad19135b953a78882e789
And attached is a screen shot.
Edit: Tried again and this time I selected the "debug the application" option. Here is the error report that came up in Visual Studio:
System.AccessViolationException was unhandled
Message: An unhandled exception of type 'System.AccessViolationException' occurred in NLua.dll
Additional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
Thank you for looking into this.
Yes, just press play, Spanish side, at 1:1 compression. I just loaded the save game twice and it crashed both times after a short while but the elapsed time before the crash varies. Here are the details of the crash as reported by Windows:
Problem signature:
Problem Event Name: APPCRASH
Application Name: Command.exe
Application Version: 1.0.0.0
Application Timestamp: 5a19a6ce
Fault Module Name: lua52.DLL
Fault Module Version: 5.2.3.0
Fault Module Timestamp: 55dc8abc
Exception Code: c0000005
Exception Offset: 00019f38
OS Version: 6.1.7601.2.1.0.256.48
Locale ID: 1033
Additional Information 1: 0a9e
Additional Information 2: 0a9e372d3b4ad19135b953a78882e789
Additional Information 3: 0a9e
Additional Information 4: 0a9e372d3b4ad19135b953a78882e789
And attached is a screen shot.
Edit: Tried again and this time I selected the "debug the application" option. Here is the error report that came up in Visual Studio:
System.AccessViolationException was unhandled
Message: An unhandled exception of type 'System.AccessViolationException' occurred in NLua.dll
Additional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
Thank you for looking into this.
- Attachments
-
- CMANO_crash.zip
- (329.31 KiB) Downloaded 20 times
RE: Application crash
Just for giggles and another data point, I ran the OP's save for an hour, three times. I didn't get a crash.
RE: Application crash
Yes, so command crashes on my machine but not on Emsoy's nor on yours apparently. It clearly points out to an issue with software running on my machine. And indeed, after rebooting and running command without any other concurrent applications it didn't crash. Given that I have not had any such issues with command for the four years I owned the game the culprit must be something I installed recently. I suspect "eM Client" but in any case, the issue appears to be confined to my particular setting rather than a problem with command. So please disregard my report and my apologies to Emsoy for wasting his time.
On the positive side, I am so glad it made you giggle. That was such a constructive contribution to the discussion. My heartfelt thanks. You made my day.
On the positive side, I am so glad it made you giggle. That was such a constructive contribution to the discussion. My heartfelt thanks. You made my day.
- michaelm75au
- Posts: 12457
- Joined: Sat May 05, 2001 8:00 am
- Location: Melbourne, Australia
RE: Application crash
can you supply your machine specs? This Lua crashing has been mentioned to me before, and I have only ever had it crash on the suspected error 2 times out of 100 tries. [ when it did crash, i couldn't get it to play up on retrying[:@]]
My PCs are are both Win7 and Win10 but only a couple of cores. Not really faster machines. This is why I am leaning to a timing issue; things happening before other things should.
My PCs are are both Win7 and Win10 but only a couple of cores. Not really faster machines. This is why I am leaning to a timing issue; things happening before other things should.
Michael
RE: Application crash
Michael, sure, here you go:
Dell Precision M6800
Intel i7-4910MQ, 2.9GHz (quad core)
16 GB DDR3 Ram
AMD Radeon HD 8950, 2GB / Intel HD Graphics 4600
Primary drive: 500 GB SSD
Win 7 SP1
But please note that I haven't had any issue on this machine for the past three years until recently. It seems that when running command without any other concurrent applications the app does not crash. I installed a new e-mail client a couple of weeks ago, "eM Client". Very nice app but if it is running at the same time as command the crashes occur although I need a little bit more experiment to be sure that the combination command/eM Client is at fault.
[Edit] After experimenting with command this weekend I must take the above comment back. On my machine command will crash even after a clean reboot and no other application running (see my post below).
Thank you.
Dell Precision M6800
Intel i7-4910MQ, 2.9GHz (quad core)
16 GB DDR3 Ram
AMD Radeon HD 8950, 2GB / Intel HD Graphics 4600
Primary drive: 500 GB SSD
Win 7 SP1
But please note that I haven't had any issue on this machine for the past three years until recently. It seems that when running command without any other concurrent applications the app does not crash. I installed a new e-mail client a couple of weeks ago, "eM Client". Very nice app but if it is running at the same time as command the crashes occur although I need a little bit more experiment to be sure that the combination command/eM Client is at fault.
[Edit] After experimenting with command this weekend I must take the above comment back. On my machine command will crash even after a clean reboot and no other application running (see my post below).
Thank you.
RE: Application crash
I hate to bring this up again but I experienced the application crash after I clean reboot and no application running but for command. The exception raised is the same as before, namely:
System.AccessViolationException was unhandled
Message: An unhandled exception of type 'System.AccessViolationException' occurred in NLua.dll
Additional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
And here is the call stack as reported by Visual Studio:
[Managed to Native Transition]
> NLua.dll!NLua.Lua.this[string].get(string fullPath)
Command.exe!Command_Core.Lua.CMANO..(Command_Core.ActiveUnit theUnit, object oldStatus)
Command.exe!Command_Core.Lua.CMANO..€()
Command.exe!Command_Core.ActiveUnit_DockingOps.()
Command.exe!Command_Core.Submarine.()
Command.exe!Command_Core.Submarine.Š()
Command.exe!Command_Core.GameGeneral.()
Command.exe!Command_Core.GameGeneral..()
mscorlib.dll!System.Threading.Tasks.Parallel.ForWorker<object>.AnonymousMethod__1()
mscorlib.dll!System.Threading.Tasks.Task.InnerInvoke()
mscorlib.dll!System.Threading.Tasks.Task.InnerInvokeWithArg(System.Threading.Tasks.Task childTask)
mscorlib.dll!System.Threading.Tasks.Task.ExecuteSelfReplicating.AnonymousMethod__0(object )
mscorlib.dll!System.Threading.Tasks.Task.InnerInvoke()
mscorlib.dll!System.Threading.Tasks.Task.Execute()
mscorlib.dll!System.Threading.Tasks.Task.ExecutionContextCallback(object obj)
mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)
mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)
mscorlib.dll!System.Threading.Tasks.Task.ExecuteWithThreadLocal(ref System.Threading.Tasks.Task currentTaskSlot)
mscorlib.dll!System.Threading.Tasks.Task.ExecuteEntry(bool bPreventDoubleExecution)
mscorlib.dll!System.Threading.Tasks.Task.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
mscorlib.dll!System.Threading.ThreadPoolWorkQueue.Dispatch()
mscorlib.dll!System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()
I have attached another save for good measure. On my machine the crash occurs shortly after loading the save but the delay varies.
Thank you.
System.AccessViolationException was unhandled
Message: An unhandled exception of type 'System.AccessViolationException' occurred in NLua.dll
Additional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
And here is the call stack as reported by Visual Studio:
[Managed to Native Transition]
> NLua.dll!NLua.Lua.this[string].get(string fullPath)
Command.exe!Command_Core.Lua.CMANO..(Command_Core.ActiveUnit theUnit, object oldStatus)
Command.exe!Command_Core.Lua.CMANO..€()
Command.exe!Command_Core.ActiveUnit_DockingOps.()
Command.exe!Command_Core.Submarine.()
Command.exe!Command_Core.Submarine.Š()
Command.exe!Command_Core.GameGeneral.()
Command.exe!Command_Core.GameGeneral..()
mscorlib.dll!System.Threading.Tasks.Parallel.ForWorker<object>.AnonymousMethod__1()
mscorlib.dll!System.Threading.Tasks.Task.InnerInvoke()
mscorlib.dll!System.Threading.Tasks.Task.InnerInvokeWithArg(System.Threading.Tasks.Task childTask)
mscorlib.dll!System.Threading.Tasks.Task.ExecuteSelfReplicating.AnonymousMethod__0(object )
mscorlib.dll!System.Threading.Tasks.Task.InnerInvoke()
mscorlib.dll!System.Threading.Tasks.Task.Execute()
mscorlib.dll!System.Threading.Tasks.Task.ExecutionContextCallback(object obj)
mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)
mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)
mscorlib.dll!System.Threading.Tasks.Task.ExecuteWithThreadLocal(ref System.Threading.Tasks.Task currentTaskSlot)
mscorlib.dll!System.Threading.Tasks.Task.ExecuteEntry(bool bPreventDoubleExecution)
mscorlib.dll!System.Threading.Tasks.Task.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
mscorlib.dll!System.Threading.ThreadPoolWorkQueue.Dispatch()
mscorlib.dll!System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()
I have attached another save for good measure. On my machine the crash occurs shortly after loading the save but the delay varies.
Thank you.
- Attachments
-
- Autosave_crash.zip
- (270.81 KiB) Downloaded 17 times
RE: Application crash
Thanks JPH added to bug report
Mike
Mike
RE: Application crash
I have tried running that last save on two machines, a Surface Book 2 and an HP Omen. Both i7s and nVidia GPUs. Tried on hi fi option on and off on both PCs. Let them run 1:1 and 1:5. They all ran an hour with no crashes on those set ups. Again, just data points.
RE: Application crash
I ran on speed 1:1 and 1:30 at HP ZBook, Windows 10 x64, Core i7, NVidia/Intel HD Graphics for 15 minutes with and without attached debugger. No crashes. Looks like it is necessary to run on the same environment that has jph. May be the issue is about lua dependencies or interoperability with unmanaged code (with lua52.dll).
RE: Application crash
Thanks Filitch.
JPH have you tried a reinstall to see if it helps? Some of these oddities have occurred in the past due to old fields and people installing stuff over original installs etc. A new install might clean that up a bit.
Mike
JPH have you tried a reinstall to see if it helps? Some of these oddities have occurred in the past due to old fields and people installing stuff over original installs etc. A new install might clean that up a bit.
Mike
RE: Application crash
Sorry for the delay in answering your question Mike, I have been away for a bit.
Yes, I did a fresh new install using the 1.13 setup release installer. I loaded the Canary's cage scenario and it played for a few hours of game time. However, it eventually crashed with exactly the same call stack I reported above.
I also noticed that gsalvar reported a similar type of crash in:
http://www.matrixgames.com/forums/tm.asp?m=4374382
In particular, his report also contains references to Lua and calls to the Command_Core.Submarine() function.
I will try to install 1.12 and see whether the crashes still occur. I have played for quite a few hours with the 1.12 versions without encountering any issues in the past so it will be interesting to see what happens now.
Thanks a lot.
Yes, I did a fresh new install using the 1.13 setup release installer. I loaded the Canary's cage scenario and it played for a few hours of game time. However, it eventually crashed with exactly the same call stack I reported above.
I also noticed that gsalvar reported a similar type of crash in:
http://www.matrixgames.com/forums/tm.asp?m=4374382
In particular, his report also contains references to Lua and calls to the Command_Core.Submarine() function.
I will try to install 1.12 and see whether the crashes still occur. I have played for quite a few hours with the 1.12 versions without encountering any issues in the past so it will be interesting to see what happens now.
Thanks a lot.

