ntpd: Correct loop offset and error calculation