Skip to content
Snippets Groups Projects
Commit 0bdd86b4 authored by Dries Buytaert's avatar Dries Buytaert
Browse files

- Patch #290282 by jvandyk, kratib: correct tracking of recursion.

parent af1a0db7
No related branches found
No related tags found
No related merge requests found
......@@ -38,6 +38,7 @@
* performs the action, keyed on action ID.
*/
function actions_do($action_ids, $object = NULL, $context = NULL, $a1 = NULL, $a2 = NULL) {
// $stack tracks the number of recursive calls.
static $stack;
$stack++;
if ($stack > variable_get('actions_max_stack', 35)) {
......@@ -101,6 +102,7 @@ function actions_do($action_ids, $object = NULL, $context = NULL, $a1 = NULL, $a
$result[$action_ids] = $action_ids($object, $context, $a1, $a2);
}
}
$stack--;
return $result;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment