Skip to content

Commit 5894562

Browse files
committed
Added missing override keyword as reported by cppcheck 2.14
1 parent be4bd12 commit 5894562

File tree

15 files changed

+15
-15
lines changed

15 files changed

+15
-15
lines changed

headers/modsecurity/rule_with_actions.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class RuleWithActions : public Rule {
4343
const std::string &fileName,
4444
int lineNumber);
4545

46-
~RuleWithActions();
46+
~RuleWithActions() override;
4747

4848
virtual bool evaluate(Transaction *transaction) override;
4949

headers/modsecurity/rule_with_operator.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class RuleWithOperator : public RuleWithActions {
4545
const std::string &fileName,
4646
int lineNumber);
4747

48-
virtual ~RuleWithOperator();
48+
~RuleWithOperator() override;
4949

5050
bool evaluate(Transaction *transaction, RuleMessage &ruleMessage) override;
5151

src/actions/exec.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class Exec : public Action {
3434
: Action(action),
3535
m_script("") { }
3636

37-
~Exec() { }
37+
~Exec() override { }
3838

3939
bool evaluate(RuleWithActions *rule, Transaction *transaction) override;
4040
bool init(std::string *error) override;

src/collection/backend/in_memory-per_process.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ class InMemoryPerProcess :
7474
public Collection {
7575
public:
7676
explicit InMemoryPerProcess(const std::string &name);
77-
~InMemoryPerProcess();
77+
~InMemoryPerProcess() override;
7878
void store(const std::string &key, const std::string &value);
7979

8080
bool storeOrUpdateFirst(const std::string &key,

src/operators/fuzzy_hash.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class FuzzyHash : public Operator {
4242
: Operator("FuzzyHash", std::move(param)),
4343
m_threshold(0),
4444
m_head(NULL) { }
45-
~FuzzyHash();
45+
~FuzzyHash() override;
4646

4747
bool evaluate(Transaction *transaction, const std::string &std) override;
4848

src/operators/pm.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class Pm : public Operator {
4040
: Operator(n, std::move(param)) {
4141
m_p = acmp_create(0);
4242
}
43-
~Pm();
43+
~Pm() override;
4444
bool evaluate(Transaction *transaction, RuleWithActions *rule,
4545
const std::string &str,
4646
RuleMessage &ruleMessage) override;

src/operators/rx.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class Rx : public Operator {
4242
m_couldContainsMacro = true;
4343
}
4444

45-
~Rx() {
45+
~Rx() override {
4646
if (m_string->m_containsMacro == false && m_re != NULL) {
4747
delete m_re;
4848
m_re = NULL;

src/operators/rx_global.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class RxGlobal : public Operator {
4242
m_couldContainsMacro = true;
4343
}
4444

45-
~RxGlobal() {
45+
~RxGlobal() override {
4646
if (m_string->m_containsMacro == false && m_re != NULL) {
4747
delete m_re;
4848
m_re = NULL;

src/operators/validate_dtd.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ class ValidateDTD : public Operator {
5757
explicit ValidateDTD(std::unique_ptr<RunTimeString> param)
5858
: Operator("ValidateDTD", std::move(param)) { }
5959
#ifdef WITH_LIBXML2
60-
~ValidateDTD() { }
60+
~ValidateDTD() override { }
6161

6262
bool evaluate(Transaction *transaction, const std::string &str) override;
6363
bool init(const std::string &file, std::string *error) override;

src/operators/validate_schema.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ class ValidateSchema : public Operator {
3838
/** @ingroup ModSecurity_Operator */
3939
explicit ValidateSchema(std::unique_ptr<RunTimeString> param)
4040
: Operator("ValidateSchema", std::move(param)) { }
41-
~ValidateSchema() { }
41+
~ValidateSchema() override { }
4242
#ifdef WITH_LIBXML2
4343

4444
bool evaluate(Transaction *transaction, const std::string &str) override;

0 commit comments

Comments
 (0)