Cosmetics: Fix some static analysis report

This commit is contained in:
Felipe Zimmerle
2016-11-29 10:27:51 -03:00
parent 9bd37ccb63
commit e6b58014db
15 changed files with 43 additions and 51 deletions

View File

@@ -30,7 +30,8 @@ namespace ctl {
class RuleRemoveById : public Action {
public:
explicit RuleRemoveById(std::string action)
: Action(action, RunTimeOnlyIfMatchKind) { }
: Action(action, RunTimeOnlyIfMatchKind),
m_id(0) { }
bool init(std::string *error) override;
bool evaluate(Rule *rule, Transaction *transaction) override;

View File

@@ -30,7 +30,9 @@ namespace ctl {
class RuleRemoveTargetById : public Action {
public:
explicit RuleRemoveTargetById(std::string action)
: Action(action, RunTimeOnlyIfMatchKind) { }
: Action(action, RunTimeOnlyIfMatchKind),
m_id(0),
m_target("") { }
bool init(std::string *error) override;
bool evaluate(Rule *rule, Transaction *transaction) override;

View File

@@ -33,8 +33,8 @@ namespace actions {
class Phase : public Action {
public:
explicit Phase(std::string action) : Action(action, ConfigurationKind),
m_secRulesPhase(0),
m_phase(0) { }
m_phase(0),
m_secRulesPhase(0) { }
bool init(std::string *error) override;
bool evaluate(Rule *rule, Transaction *transaction) override;

View File

@@ -31,7 +31,10 @@ namespace actions {
class Redirect : public Action {
public:
explicit Redirect(const std::string &action)
: Action(action, RunTimeOnlyIfMatchKind) { }
: Action(action, RunTimeOnlyIfMatchKind),
m_status(0),
m_urlExpanded(""),
m_url("") { }
bool evaluate(Rule *rule, Transaction *transaction) override;
bool init(std::string *error) override;

View File

@@ -29,7 +29,11 @@ namespace actions {
class SetVar : public Action {
public:
explicit SetVar(std::string action) : Action(action) { }
explicit SetVar(std::string action) : Action(action),
m_operation(SetVarOperation::setOperation),
m_collectionName(""),
m_variableName(""),
m_predicate("") { }
bool evaluate(Rule *rule, Transaction *transaction) override;
bool init(std::string *error) override;

View File

@@ -30,7 +30,8 @@ namespace actions {
class Status : public Action {
public:
explicit Status(std::string action) : Action(action, 2) { }
explicit Status(std::string action) : Action(action, 2),
m_status(0) { }
bool init(std::string *error) override;
bool evaluate(Rule *rule, Transaction *transaction, RuleMessage *rm)