From: Andre Date: Sun, 16 Apr 2006 17:31:51 +0000 (+0200) Subject: audiod: use tv2ms to show the time difference X-Git-Tag: v0.2.12~87 X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=6fe4a634c578a19b45371798871312e712e1f817;p=paraslash.git audiod: use tv2ms to show the time difference --- diff --git a/audiod.c b/audiod.c index e1bcbd12..975b3dfe 100644 --- a/audiod.c +++ b/audiod.c @@ -797,11 +797,12 @@ static void compute_time_diff(const struct timeval *status_time) count > 10? sign : sign * time_smooth, &diff, &tmp); sa_time_diff = tmp; - PARA_INFO_LOG("time diff (cur/avg): " - "%li:%lu/%li:%lu\n", - sign * diff.tv_sec, (diff.tv_usec + 500) / 1000, - sa_time_diff_sign * sa_time_diff.tv_sec, - (sa_time_diff.tv_usec + 500)/ 1000); + PARA_INFO_LOG("time diff (cur/avg): %s%lums/%s%lums\n", + sign > 0? "+" : "-", + tv2ms(&diff), + sa_time_diff_sign ? "+" : "-", + tv2ms(&sa_time_diff) + ); } static void check_stat_line(char *line)