mirror of
https://github.com/simh/simh.git
synced 2026-05-16 18:16:53 +00:00
ETHER: Make sure SET NOASYNC is effective for Ethernet devices
- Make sure that asynchronous mode can't be changed if devices using sim_ether are already attached. - Add missing DEV_ETHER type flag for the only sim_ether using device that didn't already have it.
This commit is contained in:
10
scp.c
10
scp.c
@@ -6109,6 +6109,16 @@ if (cptr && (*cptr != 0)) /* now eol? */
|
||||
#ifdef SIM_ASYNCH_IO
|
||||
if (flag == sim_asynch_enabled) /* already set correctly? */
|
||||
return SCPE_OK;
|
||||
if (1) {
|
||||
uint32 i;
|
||||
DEVICE *dptr;
|
||||
|
||||
for (i = 1; (dptr = sim_devices[i]) != NULL; i++) { /* flush attached files */
|
||||
if ((DEV_TYPE(dptr) == DEV_ETHER) &&
|
||||
(dptr->units->flags & UNIT_ATT))
|
||||
return sim_messagef (SCPE_ALATT, "Can't change asynch mode with %s device attached\n", dptr->name);
|
||||
}
|
||||
}
|
||||
sim_asynch_enabled = flag;
|
||||
sim_timer_change_asynch ();
|
||||
if (1) {
|
||||
|
||||
Reference in New Issue
Block a user