1
0
mirror of https://github.com/simh/simh.git synced 2026-01-25 19:56:25 +00:00

SCP: add generic length limted and case independent string for all platforms

This commit is contained in:
Mark Pizzolato
2017-04-22 21:28:48 -07:00
parent 9179c4ea07
commit 168d0d9c47
4 changed files with 14 additions and 10 deletions

View File

@@ -861,7 +861,7 @@ CONST char *cptr;
int32 saved_switches = sim_switches;
t_stat stat;
sim_strlcpy (cbuf, sim_rem_command_buf, sizeof (cbuf));
strlcpy (cbuf, sim_rem_command_buf, sizeof (cbuf));
while (isspace(cbuf[0]))
memmove (cbuf, cbuf+1, strlen(cbuf+1)+1); /* skip leading whitespace */
sim_sub_args (cbuf, sizeof(cbuf), argv);
@@ -3598,8 +3598,8 @@ static t_stat sim_os_ttinit (void) {
SIOUXSettings.toppixel = 42;
SIOUXSettings.leftpixel = 6;
iBeamCursorH = GetCursor(iBeamCursor);
sim_strlcat(title, sim_name, sizeof(title));
sim_strlcat(title, " Simulator", sizeof(title));
strlcat(title, sim_name, sizeof(title));
strlcat(title, " Simulator", sizeof(title));
title[0] = strlen(title) - 1; /* Pascal string done */
for (i = 0; i <= title[0]; i++) { /* copy to unsigned char */
ptitle[i] = title[i];