SDL-Hercules-390 / hyperion

The SDL Hercules 4.x Hyperion version of the System/370, ESA/390, and z/Architecture Emulator
Other
240 stars 90 forks source link

Fix 3705 crash on attach/detach/attach. #581

Closed jmaynard closed 1 year ago

jmaynard commented 1 year ago

If a 3705 device is attached, detached, and attached again, Hercules crashes to desktop.

Reproduce:

attach 590 3705 lport=3705
detach 590
attach 590 3705 lport=3705

The DEVBLK was never being marked as in use and needing closing. Code did reset the dev->fd to -1 to indicate it was no longer in use, and checked it, but never actually set it. Since the fd isn't used for anything but this purpose, it'ss et to a nonsense positive value.

Juergen-Git commented 1 year ago

Thanks, Jay :-)