Limit EN_STARTTIME parameter value to SECperDAY
Limit `EN_STARTTIME` parameter value to a maximum of `SECperDAY`, and return an error code if this is exceeded.
This commit is contained in:
@@ -1592,7 +1592,7 @@ int DLLEXPORT EN_settimeparam(EN_Project p, int param, long value)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case EN_STARTTIME:
|
case EN_STARTTIME:
|
||||||
if (value < 0) return 213;
|
if (value < 0 || value > SECperDAY) return 213;
|
||||||
time->Tstart = value;
|
time->Tstart = value;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user