]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
sys_macosx: fix adjustment correction after step
authorBryan Christianson <bryan@whatroute.net>
Wed, 9 Dec 2015 07:11:06 +0000 (20:11 +1300)
committerMiroslav Lichvar <mlichvar@redhat.com>
Thu, 10 Dec 2015 14:25:24 +0000 (15:25 +0100)
The desired offset was being added to the current time instead of being
subtracted.

sys_macosx.c

index c1592ddd864d947845b9360036d8a0510ceac6cb..fb2a70e9a4ec4beb2eabcc6903994a22947cd647 100644 (file)
@@ -248,7 +248,7 @@ apply_step_offset(double offset)
     return 0;
   }
 
-  UTI_AddDoubleToTimeval(&T0, offset, &T1);
+  UTI_AddDoubleToTimeval(&T0, -offset, &T1);
   T0 = T1;
 
   start_adjust();