Fixed incorrect OSDItrunc() state index when $limit is present.

This commit is contained in:
Árpád Bűrmen 2024-12-04 14:18:56 +01:00 committed by Holger Vogt
parent bf6ed080cf
commit 727f11edf0
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ int OSDItrunc(GENmodel *in_model, CKTcircuit *ckt, double *timestep) {
}
}
int state = inst->GENstate;
int state = inst->GENstate + (int)descr->num_states;
for (uint32_t i = 0; i < descr->num_nodes; i++) {
if (descr->nodes[i].react_residual_off != UINT32_MAX) {
CKTterr(state, ckt, timestep);