Skip to content

Commit

Permalink
fix allowed memory size of
Browse files Browse the repository at this point in the history
  • Loading branch information
sy-records authored May 10, 2019
1 parent f48f8a2 commit 038f621
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/Profile/Analyzer.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,12 @@ public function getParents($record, $records)
$parent = $records[$record->parent_function];

if (isset($records[$record->parent_function])) {
$parents = array_merge($this->getParents($parent, $records), [$parent]);
// fix allowed memory size of
unset($records[$record->parent_function]);
$tmp = $this->getParents($parent, $records);
if (is_array($tmp)) {
$parents = array_merge($tmp, [$parent]);
}
}
return $parents;
}
Expand Down

0 comments on commit 038f621

Please sign in to comment.