diff options
Diffstat (limited to 'stvw_cfg.c')
-rwxr-xr-x | stvw_cfg.c | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -1,7 +1,7 @@ /* * stvw_cfg.h: VDR on Smart TV plugin * - * Copyright (C) 2012, 2013 T. Lohmar + * Copyright (C) 2012 - 2016 T. Lohmar * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -35,7 +35,7 @@ cSmartTvConfig::cSmartTvConfig(): mConfigDir(""), mLog(NULL), mCfgFile(NULL), mU mLogFile(), mMediaFolder(), mSegmentDuration(), mHasMinBufferTime(), mHasBitrateCorrection(), mLiveChannels(), mGroupSep(IGNORE), mServerAddress(""), mServerPort(8000), mCmds(false), mUseStreamDev4Live(true), mBuiltInLiveStartMode (4), mBuiltInLivePktBuf4Hd(150), mBuiltInLivePktBuf4Sd(75), mBuiltInLiveBufDur(0.6), - mAddCorsHeader(false), mCorsHeaderPyld() { + mAddCorsHeader(false), mCorsHeaderPyld(), mUsageStatsLogFile("") { #ifndef STANDALONE mLogFile= ""; @@ -79,6 +79,8 @@ void cSmartTvConfig::Store(cPlugin *mPlugin) { mPlugin->SetupStore("CorsHeader", mCorsHeaderPyld.c_str()); else mPlugin->SetupStore("CorsHeader"); + if (mUsageStatsLogFile.length() != 0) + mPlugin->SetupStore("UsageStatsLogFile", mUsageStatsLogFile.c_str()); } bool cSmartTvConfig::SetupParse(const char *name, const char *value) { @@ -125,6 +127,9 @@ bool cSmartTvConfig::SetupParse(const char *name, const char *value) { mAddCorsHeader = true; mCorsHeaderPyld = value; } + else if (strcmp(name, "UsageStatsLogFile") == 0) { + mUsageStatsLogFile = value; + } else return false; @@ -303,6 +308,11 @@ void cSmartTvConfig::readConfig() { mCorsHeaderPyld = value; continue; } + + if (strcmp(attr, "UsageStatsLogFile") == 0) { + mUsageStatsLogFile = value; + continue; + } #ifndef STANDALONE esyslog("WARNING in SmartTvWeb: Attribute= %s with value= %s was not processed, thus ignored.", attr, value); |