]> git.ipfire.org Git - thirdparty/ntp.git/commitdiff
Cleanup from Dave Mills
authorHarlan Stenn <stenn@ntp.org>
Tue, 5 Oct 2004 22:27:54 +0000 (18:27 -0400)
committerHarlan Stenn <stenn@ntp.org>
Tue, 5 Oct 2004 22:27:54 +0000 (18:27 -0400)
bk: 41631fea87sZAubm1hmGX_xavUh-ZA

ntpd/ntp_control.c
ntpd/ntp_loopfilter.c
ntpd/ntp_request.c
ntpd/ntp_util.c

index f1bf5bc831845ca7c8571ba417f1918f5ab4c934..68a54ac4bebeb42110ce172f0cbd83539efed299 100644 (file)
@@ -149,8 +149,8 @@ static      u_char def_sys_var[] = {
        CS_STATE,
        CS_OFFSET,
        CS_DRIFT,
-       CS_ERROR,
        CS_JITTER,
+       CS_ERROR,
        CS_STABIL,
 #ifdef OPENSSL
        CS_HOST,
@@ -1279,7 +1279,7 @@ ctl_putsys(
 
        case CS_STABIL:
                ctl_putdbl(sys_var[CS_STABIL].text, clock_stability *
-                   1e6);
+                   1e3);
                break;
 
        case CS_VARLIST:
index 9fd776ba75cbb5274ed4e06fba5932f474617890..7ddc390721ad11b37490a49107552426b7ac58fa 100644 (file)
@@ -664,14 +664,14 @@ local_clock(
        /*
         * Yibbidy, yibbbidy, yibbidy; that'h all folks.
         */
-       record_loop_stats(last_offset, drift_comp, clock_jitter,
+       record_loop_stats(clock_offset, drift_comp, clock_jitter,
            clock_stability, sys_poll);
 #ifdef DEBUG
        if (debug)
                printf(
-                   "local_clock: mu %lu jitr %.3f freq %.3f stab %.3f poll %d count %d\n",
-                   mu, clock_jitter, drift_comp * 1e6, clock_stability *
-                   1e6, sys_poll, tc_counter);
+                   "local_clock: mu %lu jitr %.6f freq %.3f stab %.6f poll %d count %d\n",
+                   mu, clock_jitter, drift_comp * 1e6, clock_stability,
+                   sys_poll, tc_counter);
 #endif /* DEBUG */
        return (rval);
 #endif /* LOCKCLOCK */
index 2ca67fd5d336a3915044b0c6cdc115fe2d95cb25..b067b9a788676ae399b0d21963332ef86bcf87b7 100644 (file)
@@ -1047,7 +1047,7 @@ sys_info(
        is->rootdelay = htonl(DTOFP(sys_rootdelay));
        is->rootdispersion = htonl(DTOUFP(sys_rootdispersion));
        is->frequency = htonl(DTOFP(sys_jitter));
-       is->stability = htonl(DTOUFP(clock_stability * 1e6));
+       is->stability = htonl(DTOUFP(clock_stability));
        is->refid = sys_refid;
        HTONL_FP(&sys_reftime, &is->reftime);
 
index 135f9b3642f90a10ad34c75a3e3c4353e8674933..5156d4d242b2f6ee4bc6650977a55255b814076a 100644 (file)
@@ -535,9 +535,9 @@ record_loop_stats(
        day = now.l_ui / 86400 + MJD_1900;
        now.l_ui %= 86400;
        if (loopstats.fp != NULL) {
-               fprintf(loopstats.fp, "%lu %s %.9f %.6f %.9f %.6f %d\n",
+               fprintf(loopstats.fp, "%lu %s %.9f %.6f %.9f %.9f %d\n",
                    day, ulfptoa(&now, 3), offset, freq * 1e6, jitter,
-                   stability * 1e6, spoll);
+                   stability, spoll);
                fflush(loopstats.fp);
        }
 }