//-----------------------------------------------------------------------------
RS::SETTINGS::SETTINGS()
: sendPeriod(0),
- port(0),
- errorStr(),
- netRouters(),
- userParams(),
- password(),
- subnetFile()
+ port(0)
{
}
//-----------------------------------------------------------------------------
///////////////////////////
pv.param = "Port";
pvi = find(s.moduleParams.begin(), s.moduleParams.end(), pv);
-if (pvi == s.moduleParams.end())
+if (pvi == s.moduleParams.end() || pvi->value.empty())
{
errorStr = "Parameter \'Port\' not found.";
printfd(__FILE__, "Parameter 'Port' not found\n");
///////////////////////////
pv.param = "SendPeriod";
pvi = find(s.moduleParams.begin(), s.moduleParams.end(), pv);
-if (pvi == s.moduleParams.end())
+if (pvi == s.moduleParams.end() || pvi->value.empty())
{
errorStr = "Parameter \'SendPeriod\' not found.";
printfd(__FILE__, "Parameter 'SendPeriod' not found\n");
///////////////////////////
pv.param = "UserParams";
pvi = find(s.moduleParams.begin(), s.moduleParams.end(), pv);
-if (pvi == s.moduleParams.end())
+if (pvi == s.moduleParams.end() || pvi->value.empty())
{
errorStr = "Parameter \'UserParams\' not found.";
printfd(__FILE__, "Parameter 'UserParams' not found\n");
///////////////////////////
pv.param = "Password";
pvi = find(s.moduleParams.begin(), s.moduleParams.end(), pv);
-if (pvi == s.moduleParams.end())
+if (pvi == s.moduleParams.end() || pvi->value.empty())
{
errorStr = "Parameter \'Password\' not found.";
printfd(__FILE__, "Parameter 'Password' not found\n");
///////////////////////////
pv.param = "SubnetFile";
pvi = find(s.moduleParams.begin(), s.moduleParams.end(), pv);
-if (pvi == s.moduleParams.end())
+if (pvi == s.moduleParams.end() || pvi->value.empty())
{
errorStr = "Parameter \'SubnetFile\' not found.";
printfd(__FILE__, "Parameter 'SubnetFile' not found\n");
return 0;
}
//-----------------------------------------------------------------------------
-int REMOTE_SCRIPT::Reload()
+int REMOTE_SCRIPT::Reload(const MODULE_SETTINGS & ms)
{
NRMapParser nrMapParser;