From e4efba96ba3f2d77eb75fc27631e590c8be3c879 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Wed, 1 Jun 2016 18:59:09 +0200 Subject: [PATCH 1/1] server: Fix --autoplay-delay. init_vss_task() is called before the scheduler has initialized the timeval available everywhere through the global now pointer. Hence, in this function ->now is {0, 0}, and the computed autoplay barrier will be in the past, effectively making --autoplay-delay a no-op. Fix this by calling clock_get_realtime() to get the current time. --- vss.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vss.c b/vss.c index 51db7686..2acff1cb 100644 --- a/vss.c +++ b/vss.c @@ -1187,7 +1187,7 @@ void init_vss_task(int afs_socket, struct sched *s) mmd->vss_status_flags |= VSS_PLAYING; mmd->new_vss_status_flags |= VSS_PLAYING; ms2tv(autoplay_delay, &tmp); - tv_add(now, &tmp, &vsst->autoplay_barrier); + tv_add(clock_get_realtime(NULL), &tmp, &vsst->autoplay_barrier); tv_add(&vsst->autoplay_barrier, &vsst->announce_tv, &vsst->data_send_barrier); } -- 2.39.2