summaryrefslogtreecommitdiff
path: root/service.c
diff options
context:
space:
mode:
authormrwastl <mrwastl@users.sourceforge.net>2011-06-11 20:08:26 +0200
committermrwastl <mrwastl@users.sourceforge.net>2011-06-11 20:08:26 +0200
commitae0bb23a94f1063cc95bf25ca6c6c66cd2e00c59 (patch)
tree0a42f20e5e435309162adba0380f433ae394ac8c /service.c
parentd6d6aff8e0f14ba02754f875f41b354387e7e9f5 (diff)
downloadvdr-plugin-graphlcd-ae0bb23a94f1063cc95bf25ca6c6c66cd2e00c59.tar.gz
vdr-plugin-graphlcd-ae0bb23a94f1063cc95bf25ca6c6c66cd2e00c59.tar.bz2
initialise strings
Diffstat (limited to 'service.c')
-rw-r--r--service.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/service.c b/service.c
index f1a043a..9399e75 100644
--- a/service.c
+++ b/service.c
@@ -35,6 +35,20 @@ cGraphLCDService::cGraphLCDService(cGraphLCDState * state)
lcrUpdateDelay = 60000; // 60 sec
femonUpdateDelay = 2000; // 2 sec
mailboxUpdateDelay = 10000; // 10 sec
+
+ // pre-init strings
+ checkRTSData.rds_text = (char*)"";
+ checkRTSData.rds_title = (char*)"";
+ checkRTSData.rds_artist = (char*)"";
+
+ checkLcrData.destination = (char*)"";
+ checkLcrData.price = (char*)"";
+ checkLcrData.pulse = (char*)"";
+
+#if 0
+ currFemonData.fe_name = (char*)"";
+ currFemonData.fe_status = (char*)"";
+#endif
}
cGraphLCDService::~cGraphLCDService()
@@ -213,7 +227,7 @@ GLCD::cType cGraphLCDService::GetItem(const std::string & ServiceName, const std
if (ItemName == "" || ItemName == "default"|| ItemName == "hasnew") {
return (bool)currMailboxNewData;
} else if (ItemName == "newcount") {
- if (currMailboxUnseenData > (long)std::numeric_limits<int>::max()) {
+ if (currMailboxUnseenData > (unsigned long)std::numeric_limits<int>::max()) {
return (int)-1;
} else {
return (int)currMailboxUnseenData;
@@ -246,9 +260,9 @@ bool cGraphLCDService::NeedsUpdate(uint64_t CurrentTime)
radioLastChange = CurrentTime;
p = cPluginManager::CallFirstService("RadioTextService-v1.0", NULL);
if (p) {
+ checkRTSData.rds_text = NULL;
checkRTSData.rds_title = NULL;
checkRTSData.rds_artist = NULL;
- checkRTSData.title_start = NULL;
if (cPluginManager::CallFirstService("RadioTextService-v1.0", &checkRTSData)) {
radioActive = true;