reference: clamp local stratum set from cmdmon

This commit is contained in:
Miroslav Lichvar 2016-04-08 12:34:48 +02:00
parent 4d1c795804
commit 5084a8b342

View file

@ -1314,7 +1314,7 @@ void
REF_EnableLocal(int stratum) REF_EnableLocal(int stratum)
{ {
enable_local_stratum = 1; enable_local_stratum = 1;
local_stratum = stratum; local_stratum = CLAMP(1, stratum, NTP_MAX_STRATUM - 1);
} }
/* ================================================== */ /* ================================================== */