From: Mike Brady <4265913+mikebrady@users.noreply.github.com> Date: Sun, 28 Nov 2021 16:06:43 +0000 (+0000) Subject: Clang Format X-Git-Tag: 1.2~70 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=12e2e6339c8efc4c58c8b67d3c19d45112c2abeb;p=thirdparty%2Fnqptp.git Clang Format --- diff --git a/nqptp-message-handlers.c b/nqptp-message-handlers.c index 1637111..acfa561 100644 --- a/nqptp-message-handlers.c +++ b/nqptp-message-handlers.c @@ -367,14 +367,14 @@ void handle_follow_up(char *buf, __attribute__((unused)) ssize_t recv_len, // Do acceptance checking. - // Positive changes in the offset are much more likely to be + // Positive changes in the offset are much more likely to be // legitimate, since they could only occur due to a shorter // propagation time. (Actually, this is not quite true -- // it is possible that the remote clock could be adjusted forward - // and this would increase the offset too.) + // and this would increase the offset too.) // Anyway, when the clock is new, we give preferential weighting to // positive changes in the offset. - + // If the new offset is greater, by any amount, than the old offset, // or if it is less by up to 10 mS, // accept it. @@ -388,8 +388,10 @@ void handle_follow_up(char *buf, __attribute__((unused)) ssize_t recv_len, // we take any positive or a limited negative jitter as a sync event if (jitter < 0) offset = clock_private_info->previous_offset + jitter / 32; - else if (clock_private_info->follow_up_number < (5 * 8)) // at the beginning (8 samples per second) - offset = clock_private_info->previous_offset + jitter / 2; // accept positive changes quickly + else if (clock_private_info->follow_up_number < + (5 * 8)) // at the beginning (8 samples per second) + offset = + clock_private_info->previous_offset + jitter / 2; // accept positive changes quickly else offset = clock_private_info->previous_offset + jitter / 2; clock_private_info->last_sync_time = reception_time;