mirror of
https://github.com/rcornwell/sims.git
synced 2026-04-29 05:06:42 +00:00
SCP: Updated to current.
This commit is contained in:
@@ -303,19 +303,19 @@ return sim_set_notelnet (0, NULL);
|
||||
/* Set/show data structures */
|
||||
|
||||
static CTAB set_con_tab[] = {
|
||||
{ "WRU", &sim_set_kmap, KMAP_WRU | KMAP_NZ },
|
||||
{ "BRK", &sim_set_kmap, KMAP_BRK },
|
||||
{ "DEL", &sim_set_kmap, KMAP_DEL | KMAP_NZ },
|
||||
{ "DEBUG", &sim_set_kmap, KMAP_DBGINT | KMAP_NZ },
|
||||
{ "PCHAR", &sim_set_pchar, 0 },
|
||||
{ "SPEED", &sim_set_cons_speed, 0 },
|
||||
{ "TELNET", &sim_set_telnet, 0 },
|
||||
{ "WRU", &sim_set_kmap, KMAP_WRU | KMAP_NZ },
|
||||
{ "BRK", &sim_set_kmap, KMAP_BRK },
|
||||
{ "DEL", &sim_set_kmap, KMAP_DEL | KMAP_NZ },
|
||||
{ "DBGINT", &sim_set_kmap, KMAP_DBGINT | KMAP_NZ },
|
||||
{ "PCHAR", &sim_set_pchar, 0 },
|
||||
{ "SPEED", &sim_set_cons_speed, 0 },
|
||||
{ "TELNET", &sim_set_telnet, 0 },
|
||||
{ "NOTELNET", &sim_set_notelnet, 0 },
|
||||
{ "SERIAL", &sim_set_serial, 0 },
|
||||
{ "SERIAL", &sim_set_serial, 0 },
|
||||
{ "NOSERIAL", &sim_set_noserial, 0 },
|
||||
{ "LOG", &sim_set_logon, 0 },
|
||||
{ "NOLOG", &sim_set_logoff, 0 },
|
||||
{ "DEBUG", &sim_set_debon, 0 },
|
||||
{ "LOG", &sim_set_logon, 0 },
|
||||
{ "NOLOG", &sim_set_logoff, 0 },
|
||||
{ "DEBUG", &sim_set_debon, 0 },
|
||||
{ "NODEBUG", &sim_set_deboff, 0 },
|
||||
#define CMD_WANTSTR 0100000
|
||||
{ "HALT", &sim_set_halt, 1 | CMD_WANTSTR },
|
||||
@@ -341,8 +341,8 @@ static SHTAB show_con_tab[] = {
|
||||
{ "WRU", &sim_show_kmap, KMAP_WRU },
|
||||
{ "BRK", &sim_show_kmap, KMAP_BRK },
|
||||
{ "DEL", &sim_show_kmap, KMAP_DEL },
|
||||
#if (defined(__GNUC__) && !defined(__OPTIMIZE__)) /* Debug build? */
|
||||
{ "DEBUG", &sim_show_kmap, KMAP_DBGINT },
|
||||
#if (defined(__GNUC__) && !defined(__OPTIMIZE__) && !defined(_WIN32)) /* Debug build? */
|
||||
{ "DBGINT", &sim_show_kmap, KMAP_DBGINT },
|
||||
#endif
|
||||
{ "PCHAR", &sim_show_pchar, 0 },
|
||||
{ "SPEED", &sim_show_cons_speed, 0 },
|
||||
@@ -1570,6 +1570,7 @@ for (i=(was_active_command ? sim_rem_cmd_active_line : 0);
|
||||
case '\n':
|
||||
if (rem->buf_ptr == 0)
|
||||
break;
|
||||
/* fall through */
|
||||
case '\r':
|
||||
tmxr_linemsg (lp, "\r\n");
|
||||
if (rem->buf_ptr+1 >= rem->buf_size) {
|
||||
@@ -2580,7 +2581,8 @@ while (*cptr != 0) { /* do all mods */
|
||||
if (serport != INVALID_HANDLE) {
|
||||
sim_close_serial (serport);
|
||||
if (r == SCPE_OK) {
|
||||
char cbuf[CBUFSIZE];
|
||||
char cbuf[CBUFSIZE+10];
|
||||
|
||||
if ((sim_con_tmxr.master) || /* already open? */
|
||||
(sim_con_ldsc.serport))
|
||||
sim_set_noserial (0, NULL); /* close first */
|
||||
@@ -2662,7 +2664,7 @@ else {
|
||||
if (!*pref)
|
||||
return SCPE_MEM;
|
||||
get_glyph_nc (filename, gbuf, 0); /* reparse */
|
||||
strncpy ((*pref)->name, gbuf, sizeof((*pref)->name)-1);
|
||||
strlcpy ((*pref)->name, gbuf, sizeof((*pref)->name));
|
||||
if (sim_switches & SWMASK ('N')) /* if a new log file is requested */
|
||||
*pf = sim_fopen (gbuf, (binary ? "w+b" : "w+"));/* then open an empty file */
|
||||
else /* otherwise */
|
||||
@@ -3388,6 +3390,7 @@ ControlHandler(DWORD dwCtrlType)
|
||||
case CTRL_LOGOFF_EVENT: // User is logging off
|
||||
if (!GetConsoleMode(GetStdHandle(STD_INPUT_HANDLE), &Mode))
|
||||
return TRUE; // Not our User, so ignore
|
||||
/* fall through */
|
||||
case CTRL_SHUTDOWN_EVENT: // System is shutting down
|
||||
int_handler(0);
|
||||
return TRUE;
|
||||
|
||||
Reference in New Issue
Block a user