mirror of https://github.com/arendst/Tasmota.git
Merge pull request #6504 from laurentdong/ExpressionBracket
Missed one character previous of closure bracket
This commit is contained in:
commit
55ab9639e6
|
@ -1031,7 +1031,7 @@ bool findNextObjectValue(char * &pointer, float &value)
|
|||
} else if (*pointer == '(') { //It is a sub expression bracketed with ()
|
||||
char * closureBracket = findClosureBracket(pointer); //Get the position of closure bracket ")"
|
||||
if (closureBracket != nullptr) {
|
||||
value = evaluateExpression(pointer+1, closureBracket - pointer - 2);
|
||||
value = evaluateExpression(pointer+1, closureBracket - pointer - 1);
|
||||
pointer = closureBracket + 1;
|
||||
bSucceed = true;
|
||||
}
|
||||
|
@ -1333,7 +1333,7 @@ bool findNextLogicObjectValue(char * &pointer, bool &value)
|
|||
} else if (*pointer == '(') { //It is a sub expression bracketed with ()
|
||||
char * closureBracket = findClosureBracket(pointer); //Get the position of closure bracket ")"
|
||||
if (closureBracket != nullptr) {
|
||||
value = evaluateLogicalExpression(pointer+1, closureBracket - pointer - 2);
|
||||
value = evaluateLogicalExpression(pointer+1, closureBracket - pointer - 1);
|
||||
pointer = closureBracket + 1;
|
||||
bSucceed = true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue