mirror of
https://github.com/simh/simh.git
synced 2026-04-15 16:11:13 +00:00
H316, I7094, NOVA, PDP1, PDP10, PDP8, SDS: Coverity singleton errors
Most history routines defined a local sim_eval of the proper length, but the erroneous ones were fixed length machines that defined an integer variable instead of an integer array of length 1. The VAX used the global sim_eval. The changes follow the VAX practice.
This commit is contained in:
committed by
Mark Pizzolato
parent
e9d5e2e3c9
commit
5b5e0f9c35
@@ -25,6 +25,7 @@
|
||||
|
||||
cpu central processor
|
||||
|
||||
07-Sep-17 RMS Fixed sim_eval declaration in history routine (COVERITY)
|
||||
09-Mar-17 RMS Fixed PCQ_ENTRY for interrupts (COVERITY)
|
||||
13-Feb-17 RMS RESET clear L'AC, per schematics
|
||||
28-Jan-17 RMS Renamed switch register variable to SR, per request
|
||||
@@ -1576,7 +1577,6 @@ t_stat cpu_show_hist (FILE *st, UNIT *uptr, int32 val, CONST void *desc)
|
||||
int32 l, k, di, lnt;
|
||||
const char *cptr = (const char *) desc;
|
||||
t_stat r;
|
||||
t_value sim_eval;
|
||||
InstHistory *h;
|
||||
|
||||
if (hst_lnt == 0) /* enabled? */
|
||||
@@ -1599,8 +1599,8 @@ for (k = 0; k < lnt; k++) { /* print specified */
|
||||
if (h->ir < 06000)
|
||||
fprintf (st, "%05o ", h->ea);
|
||||
else fprintf (st, " ");
|
||||
sim_eval = h->ir;
|
||||
if ((fprint_sym (st, h->pc & ADDRMASK, &sim_eval, &cpu_unit, SWMASK ('M'))) > 0)
|
||||
sim_eval[0] = h->ir;
|
||||
if ((fprint_sym (st, h->pc & ADDRMASK, sim_eval, &cpu_unit, SWMASK ('M'))) > 0)
|
||||
fprintf (st, "(undefined) %04o", h->ir);
|
||||
if (h->ir < 04000)
|
||||
fprintf (st, " [%04o]", h->opnd);
|
||||
|
||||
Reference in New Issue
Block a user