SCP: Cleanup compiler warnings
This commit is contained in:
parent
d2cfee9488
commit
833927d349
1 changed files with 4 additions and 2 deletions
6
scp.c
6
scp.c
|
@ -3030,7 +3030,8 @@ if ((*cptr == '"') || (*cptr == '\'')) {
|
||||||
return SCPE_2MARG; /* No more arguments */
|
return SCPE_2MARG; /* No more arguments */
|
||||||
if (SCPE_OK != sim_decode_quoted_string (gbuf, dbuf, &dsize))
|
if (SCPE_OK != sim_decode_quoted_string (gbuf, dbuf, &dsize))
|
||||||
return sim_messagef (SCPE_ARG, "Invalid String\n");
|
return sim_messagef (SCPE_ARG, "Invalid String\n");
|
||||||
cptr = dbuf;
|
dbuf[dsize] = 0;
|
||||||
|
cptr = (char *)dbuf;
|
||||||
}
|
}
|
||||||
sim_printf ("%s%s", cptr, (sim_switches & SWMASK('N')) ? "" : "\n");
|
sim_printf ("%s%s", cptr, (sim_switches & SWMASK('N')) ? "" : "\n");
|
||||||
return SCPE_OK;
|
return SCPE_OK;
|
||||||
|
@ -3376,7 +3377,8 @@ if ((*ip == '"') || (*ip == '\'')) { /* start with a quot
|
||||||
if (*cptr == '\0') { /* full string was quoted? */
|
if (*cptr == '\0') { /* full string was quoted? */
|
||||||
uint32 dsize;
|
uint32 dsize;
|
||||||
|
|
||||||
if (SCPE_OK == sim_decode_quoted_string (tp, tp, &dsize)) {
|
if (SCPE_OK == sim_decode_quoted_string (tp, (uint8 *)tp, &dsize)) {
|
||||||
|
tp[dsize] = '\0';
|
||||||
while (sim_isspace (*tp))
|
while (sim_isspace (*tp))
|
||||||
memmove (tp, tp + 1, strlen (tp));
|
memmove (tp, tp + 1, strlen (tp));
|
||||||
strlcpy (ip, tp, instr_size - (ip - instr));/* copy quoted contents to input buffer */
|
strlcpy (ip, tp, instr_size - (ip - instr));/* copy quoted contents to input buffer */
|
||||||
|
|
Loading…
Add table
Reference in a new issue