mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-11-19 10:44:25 +03:00
Cosmetics: Fix static analysis warnings
This commit is contained in:
@@ -101,7 +101,6 @@ void SetVar::dump() {
|
||||
|
||||
bool SetVar::evaluate(Rule *rule, Assay *assay) {
|
||||
std::string targetValue;
|
||||
int value = 0;
|
||||
std::string variableNameExpanded = MacroExpansion::expand(variableName,
|
||||
assay);
|
||||
std::string resolvedPre = MacroExpansion::expand(predicate, assay);
|
||||
@@ -112,6 +111,8 @@ bool SetVar::evaluate(Rule *rule, Assay *assay) {
|
||||
targetValue = std::string("1");
|
||||
} else {
|
||||
int pre = 0;
|
||||
int value = 0;
|
||||
|
||||
try {
|
||||
pre = stoi(resolvedPre);
|
||||
} catch (...) {
|
||||
|
||||
Reference in New Issue
Block a user