mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-03 16:35:06 -05:00
cmdmon: return error if doffset command fails
This commit is contained in:
8
cmdmon.c
8
cmdmon.c
@@ -858,9 +858,13 @@ static void
|
||||
handle_doffset(CMD_Request *rx_message, CMD_Reply *tx_message)
|
||||
{
|
||||
double doffset;
|
||||
|
||||
doffset = UTI_FloatNetworkToHost(rx_message->data.doffset.doffset);
|
||||
LCL_AccumulateOffset(doffset, 0.0);
|
||||
LOG(LOGS_INFO, "Accumulated delta offset of %.6f seconds", doffset);
|
||||
if (!LCL_AccumulateOffset(doffset, 0.0)) {
|
||||
tx_message->status = htons(STT_FAILED);
|
||||
} else {
|
||||
LOG(LOGS_INFO, "Accumulated delta offset of %.6f seconds", doffset);
|
||||
}
|
||||
}
|
||||
|
||||
/* ================================================== */
|
||||
|
||||
Reference in New Issue
Block a user