From: Bernhard Froehlich Date: Sat, 4 May 2013 12:59:52 +0000 (+0200) Subject: stime(2) is only available on Linux so make it optional. X-Git-Tag: v3.9~46^2~13 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0fdc4fc19373b6a7c19f89ca37fbca32d1be78a4;p=thirdparty%2Ftvheadend.git stime(2) is only available on Linux so make it optional. --- diff --git a/src/tvhtime.c b/src/tvhtime.c index e19d6c8d2..589840af5 100644 --- a/src/tvhtime.c +++ b/src/tvhtime.c @@ -99,7 +99,11 @@ tvhtime_update ( struct tm *tm ) if (tvhtime_update_enabled) { if (llabs(t2 - t1) > tvhtime_tolerance) { tvhlog(LOG_DEBUG, "time", "updated system clock"); +#ifdef stime stime(&now); +#else + tvhlog(LOG_NOTICE, "time", "stime(2) not implemented"); +#endif } }