@@ -1430,7 +1430,7 @@ abstract private class AccessPathFront extends TAccessPathFront {
1430
1430
1431
1431
abstract DataFlowType getType ( ) ;
1432
1432
1433
- abstract boolean toBool ( ) ;
1433
+ abstract boolean toBoolNonEmpty ( ) ;
1434
1434
1435
1435
predicate headUsesContent ( Content f ) { this = TFrontHead ( f ) }
1436
1436
}
@@ -1442,7 +1442,7 @@ private class AccessPathFrontNil extends AccessPathFront, TFrontNil {
1442
1442
1443
1443
override DataFlowType getType ( ) { this = TFrontNil ( result ) }
1444
1444
1445
- override boolean toBool ( ) { result = false }
1445
+ override boolean toBoolNonEmpty ( ) { result = false }
1446
1446
}
1447
1447
1448
1448
private class AccessPathFrontHead extends AccessPathFront , TFrontHead {
@@ -1452,7 +1452,7 @@ private class AccessPathFrontHead extends AccessPathFront, TFrontHead {
1452
1452
exists ( Content head | this = TFrontHead ( head ) | result = head .getContainerType ( ) )
1453
1453
}
1454
1454
1455
- override boolean toBool ( ) { result = true }
1455
+ override boolean toBoolNonEmpty ( ) { result = true }
1456
1456
}
1457
1457
1458
1458
/**
@@ -1477,6 +1477,16 @@ private predicate flowCandFwd0(
1477
1477
fromArg = false and
1478
1478
apf = TFrontNil ( node .getErasedNodeTypeBound ( ) )
1479
1479
or
1480
+ exists ( NodeExt mid |
1481
+ flowCandFwd ( mid , fromArg , apf , config ) and
1482
+ localFlowBigStepExt ( mid , node , true , _, config )
1483
+ )
1484
+ or
1485
+ exists ( NodeExt mid , AccessPathFrontNil nil |
1486
+ flowCandFwd ( mid , fromArg , nil , config ) and
1487
+ localFlowBigStepExt ( mid , node , false , apf , config )
1488
+ )
1489
+ or
1480
1490
nodeCand2 ( node , unbind ( config ) ) and
1481
1491
(
1482
1492
exists ( NodeExt mid |
@@ -1518,16 +1528,6 @@ private predicate flowCandFwd0(
1518
1528
)
1519
1529
)
1520
1530
or
1521
- exists ( NodeExt mid |
1522
- flowCandFwd ( mid , fromArg , apf , config ) and
1523
- localFlowBigStepExt ( mid , node , true , _, config )
1524
- )
1525
- or
1526
- exists ( NodeExt mid , AccessPathFrontNil nil |
1527
- flowCandFwd ( mid , fromArg , nil , config ) and
1528
- localFlowBigStepExt ( mid , node , false , apf , config )
1529
- )
1530
- or
1531
1531
exists ( NodeExt mid , Content f |
1532
1532
flowCandFwd ( mid , fromArg , _, config ) and
1533
1533
storeExtCand2 ( mid , f , node , config ) and
@@ -1538,7 +1538,7 @@ private predicate flowCandFwd0(
1538
1538
exists ( Content f |
1539
1539
flowCandFwdRead ( f , node , fromArg , config ) and
1540
1540
consCandFwd ( f , apf , config ) and
1541
- nodeCand2 ( node , _, unbindBool ( apf .toBool ( ) ) , unbind ( config ) )
1541
+ nodeCand2 ( node , _, unbindBool ( apf .toBoolNonEmpty ( ) ) , unbind ( config ) )
1542
1542
)
1543
1543
}
1544
1544
@@ -1897,7 +1897,7 @@ private predicate flowFwdStore1(
1897
1897
flowFwdStore0 ( mid , f , node , apf0 , config ) and
1898
1898
consCand ( f , apf0 , config ) and
1899
1899
apf .headUsesContent ( f ) and
1900
- flowCand ( node , _, apf , config )
1900
+ flowCand ( node , _, apf , unbind ( config ) )
1901
1901
}
1902
1902
1903
1903
pragma [ nomagic]
@@ -2025,7 +2025,8 @@ private predicate readFwd(
2025
2025
) {
2026
2026
readExtCand2 ( node1 , f , node2 , config ) and
2027
2027
flowFwdRead ( node2 , f , ap , _, config ) and
2028
- ap0 = pop ( f , ap )
2028
+ ap0 = pop ( f , ap ) and
2029
+ flowConsCandFwd ( f , _, ap0 , unbind ( config ) )
2029
2030
}
2030
2031
2031
2032
pragma [ nomagic]
0 commit comments