mbbsemu / MBBSEmu

The MajorBBS Emulation Project is an Open Source, Cross-Platform emulator for easily running The MajorBBS & Worldgroup Modules
https://www.mbbsemu.com
MIT License
129 stars 14 forks source link

[ELWSS] Sub Striker - MBBSEmu crashes when connecting #135

Closed tuday2 closed 3 years ago

tuday2 commented 3 years ago

Module Information

Describe the bug MBBSEmu crashes when connecting to telnet (only 1 module loaded)

To Reproduce Steps to reproduce the behavior:

  1. Add module to moduleConfig.json
  2. Load MBBSEmu
  3. Connect to telnet port
  4. See error

Expected behavior Module loads and able to connect to BBS

Screenshots

Unhandled exception. System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values. (Parameter 'Unable to locate FFFF:02E1')
   at MBBSEmu.Memory.MemoryCore.GetWord(UInt16 segment, UInt16 offset)
   at MBBSEmu.HostProcess.ExecutionUnits.ExecutionUnit.Execute(IntPtr16 entryPoint, UInt16 channelNumber, Boolean simulateCallFar, Boolean bypassState, Queue`1 initialStackValues, UInt16 initialStackPointer)
   at MBBSEmu.Module.MbbsModule.Execute(IntPtr16 entryPoint, UInt16 channelNumber, Boolean simulateCallFar, Boolean bypassSetState, Queue`1 initialStackValues, UInt16 initialStackPointer)
   at MBBSEmu.HostProcess.MbbsHost.WorkerThread()
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location where exception was thrown ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()

Software Information:

enusbaum commented 3 years ago

Ordinal MAJORBBS.737 is _8087 which looks to signal to the program if an x87 math co-processor is present.

image

In this case, it appears we can return a constant of 3 to denote the presence of an x87 FPU and process the FPU command FCOS normally.