durable_rules 2.0.8 → 2.0.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/src/rules/events.c +24 -22
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cfa1e57dda8143326832f1c3fda960c12f1c86b5
|
4
|
+
data.tar.gz: f448dd2fe6abcbb32f56f33e33f3048e4ab0fb10
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d58e95f7a9364dc84a1296c6db45fcefbabcf4c54e01c904e2d41722a482ae4d384ebaaaa1b9ff3f9a91c4396fb26c8126ac3be3a1c7c1041bc682156ab3d01
|
7
|
+
data.tar.gz: ee9107a906fe6e38519d43805a7a790406d6e677aba8a4074a27c6fd4d98bb92b07960296f3a22d76f59247861b4c5d387082eac2f2997711af9ba45c191fb01
|
data/src/rules/events.c
CHANGED
@@ -1558,31 +1558,33 @@ static unsigned int isArrayMatch(ruleset *tree,
|
|
1558
1558
|
for(unsigned int propertyIndex = 0; propertyIndex < jo.propertiesLength; ++propertyIndex) {
|
1559
1559
|
jsonProperty *currentProperty = &jo.properties[propertyIndex];
|
1560
1560
|
for (unsigned int entry = currentProperty->hash & HASH_MASK; nextHashset[entry] != 0; entry = (entry + 1) % NEXT_BUCKET_LENGTH) {
|
1561
|
-
node *hashNode = &tree->nodePool[nextHashset[entry]];
|
1562
|
-
if (
|
1563
|
-
|
1564
|
-
|
1565
|
-
|
1566
|
-
|
1567
|
-
|
1568
|
-
|
1569
|
-
|
1570
|
-
|
1571
|
-
|
1572
|
-
|
1573
|
-
|
1561
|
+
node *hashNode = &tree->nodePool[nextHashset[entry]];
|
1562
|
+
if (currentProperty->hash == hashNode->value.a.expression.left.value.id.propertyNameHash) {
|
1563
|
+
if (hashNode->value.a.expression.operator == OP_IALL || hashNode->value.a.expression.operator == OP_IANY) {
|
1564
|
+
CHECK_RESULT(isArrayMatch(tree,
|
1565
|
+
&jo,
|
1566
|
+
currentProperty,
|
1567
|
+
&hashNode->value.a,
|
1568
|
+
propertyMatch));
|
1569
|
+
} else {
|
1570
|
+
CHECK_RESULT(isAlphaMatch(tree,
|
1571
|
+
&hashNode->value.a,
|
1572
|
+
&jo,
|
1573
|
+
propertyMatch));
|
1574
|
+
}
|
1574
1575
|
|
1575
|
-
|
1576
|
-
|
1577
|
-
|
1578
|
-
|
1579
|
-
|
1576
|
+
if (*propertyMatch && hashNode->value.a.nextOffset) {
|
1577
|
+
CHECK_RESULT(isNextMatch(tree,
|
1578
|
+
&jo,
|
1579
|
+
&hashNode->value.a,
|
1580
|
+
propertyMatch));
|
1580
1581
|
|
1581
|
-
|
1582
|
+
}
|
1582
1583
|
|
1583
|
-
|
1584
|
-
|
1585
|
-
|
1584
|
+
if (*propertyMatch && (hashNode->value.a.nextOffset || hashNode->value.a.nextListOffset)) {
|
1585
|
+
break;
|
1586
|
+
}
|
1587
|
+
}
|
1586
1588
|
}
|
1587
1589
|
}
|
1588
1590
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: durable_rules
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jesus Ruiz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-10-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|