summaryrefslogtreecommitdiff
path: root/p2pvr/daemon/maintenance.cpp
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2015-06-18 00:25:45 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2015-06-18 00:25:45 +0100
commit3d154e756d61d8617bb8023eb552b5e4faab2a74 (patch)
treea887a65f8699e7dbf46e8d50c25b575e50d498b2 /p2pvr/daemon/maintenance.cpp
parentMerge branch 'netfs-test-refactor' (diff)
parentCompatibility with AppInstance and ExecContext changes (diff)
downloadp2pvr-3d154e756d61d8617bb8023eb552b5e4faab2a74.tar.bz2
p2pvr-3d154e756d61d8617bb8023eb552b5e4faab2a74.tar.xz
p2pvr-3d154e756d61d8617bb8023eb552b5e4faab2a74.zip
Merge branch 'p2pvr'
Diffstat (limited to 'p2pvr/daemon/maintenance.cpp')
-rw-r--r--p2pvr/daemon/maintenance.cpp12
1 files changed, 7 insertions, 5 deletions
diff --git a/p2pvr/daemon/maintenance.cpp b/p2pvr/daemon/maintenance.cpp
index 8e204f7..928e8d9 100644
--- a/p2pvr/daemon/maintenance.cpp
+++ b/p2pvr/daemon/maintenance.cpp
@@ -29,7 +29,9 @@ Maintenance::Maintenance(Ice::ObjectAdapterPtr a, IceUtil::TimerPtr t) :
lastUpdateEvents(0),
updateRunning(false)
{
- timer->scheduleRepeated(clientCheck, IceUtil::Time::seconds(5 * 60));
+ if (timer) {
+ timer->scheduleRepeated(clientCheck, IceUtil::Time::seconds(5 * 60));
+ }
#ifdef NDEBUG
ScheduledUpdate();
#endif
@@ -48,8 +50,8 @@ void
Maintenance::UpdateAll(short type, const Ice::Current & ice)
{
UpdateNetwork(type, ice);
- UpdateServices(type, ice);
- UpdateEvents(type, ice);
+ UpdateServices(ice);
+ UpdateEvents(ice);
}
void
@@ -70,12 +72,12 @@ Maintenance::ScheduledUpdate()
}
if (lastUpdateServices < now - periodUpdateServices) {
Logger()->messagebf(LOG_INFO, "%s: updating services", __PRETTY_FUNCTION__);
- si->UpdateServices(FE_OFDM);
+ si->UpdateServices();
time(&lastUpdateServices);
}
if (lastUpdateEvents < now - periodUpdateEvents) {
Logger()->messagebf(LOG_INFO, "%s: updating events", __PRETTY_FUNCTION__);
- si->UpdateEvents(FE_OFDM);
+ si->UpdateEvents();
time(&lastUpdateEvents);
}
Logger()->messagebf(LOG_DEBUG, "%s: completed", __PRETTY_FUNCTION__);