mirror of
https://github.com/github/codeql.git
synced 2026-07-06 20:15:37 +02:00
Bug fix:
When getting the wrapper for the root node, we must give the container of the root node, not the endpoint, because they won't necessarily be the same for functions contained within functions.
This commit is contained in:
@@ -60,7 +60,7 @@ private string getTokenFeature(DataFlow::Node endpoint, string featureName) {
|
||||
) and
|
||||
rootNode =
|
||||
NeighborhoodBodies::getNeighborhoodAstNode(Raw::astNode(endpoint.getAstNode()), thresh) and
|
||||
rootNodeWrapped = DatabaseFeatures::astNode(Wrapped::astNode(endpoint.getContainer(), rootNode)) and
|
||||
rootNodeWrapped = DatabaseFeatures::astNode(Wrapped::astNode(rootNode.getContainer(), rootNode)) and
|
||||
result =
|
||||
unique(string x |
|
||||
x = NeighborhoodBodies::getBodyTokenFeatureForNeighborhoodNode(rootNodeWrapped)
|
||||
|
||||
Reference in New Issue
Block a user