1
0
mirror of https://github.com/simh/simh.git synced 2026-04-30 21:38:32 +00:00

Fix to properly report device attention when a manual detach operation is performed (from Bob Supnik)

This commit is contained in:
Mark Pizzolato
2012-12-08 14:30:00 -08:00
parent ac8bd2521b
commit cb659d6c83
2 changed files with 6 additions and 1 deletions

View File

@@ -1155,6 +1155,7 @@ return SCPE_OK;
t_stat rp_detach (UNIT *uptr)
{
int32 drv;
extern int32 sim_is_running;
if (!(uptr->flags & UNIT_ATT)) /* attached? */
return SCPE_OK;
@@ -1167,7 +1168,8 @@ if (sim_is_active (uptr)) { /* unit active? */
if (uptr->FUNC >= FNC_WCHK) /* data transfer? */
rpcs1 = rpcs1 | CS1_DONE | CS1_TRE; /* set done, err */
}
update_rpcs (CS1_SC, drv); /* request intr */
if (!sim_is_running) /* from console? */
update_rpcs (CS1_SC, drv); /* request intr */
return detach_unit (uptr);
}