Skip to content

Commit

Permalink
Fix taint regression
Browse files Browse the repository at this point in the history
  • Loading branch information
muglug committed Jun 20, 2020
1 parent 80ed1da commit 8edee96
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1243,18 +1243,22 @@ function (Assertion $assertion) use ($generic_params) : Assertion {
) {
$code_location = new CodeLocation($statements_analyzer->getSource(), $stmt);

$method_location = $method_storage
? ($method_storage->signature_return_type_location ?: $method_storage->location)
: null;

if ($method_storage && $method_storage->pure) {
$method_source = TaintNode::getForMethodReturn(
(string) $method_id,
$cased_method_id,
$code_location,
$method_location,
$code_location
);
} else {
$method_source = TaintNode::getForMethodReturn(
(string) $method_id,
$cased_method_id,
$code_location
$method_location
);
}

Expand Down

0 comments on commit 8edee96

Please sign in to comment.