Merge pull request #880 from alissamueller/dev-pumpstatus-bugfix

Fixes Bug in EN_setlinkvalue
This commit is contained in:
Lew Rossman
2025-09-23 10:43:53 -04:00
committed by GitHub

View File

@@ -4132,10 +4132,9 @@ int DLLEXPORT EN_setlinkvalue(EN_Project p, int index, int property, double valu
if (Link[index].Type == CVPIPE) return 207; if (Link[index].Type == CVPIPE) return 207;
s = (char)ROUND(value); s = (char)ROUND(value);
if (s < 0 || s > 2) return 211; if (s < 0 || s > 2) return 211;
s = s + CLOSED;
if (property == EN_INITSTATUS) if (property == EN_INITSTATUS)
{ {
Link[index].InitStatus = s; Link[index].InitStatus = s + CLOSED;
} }
else else
{ {