Skip to content

Commit

Permalink
[modxcms#9859] Prevent conditional output filter recursion
Browse files Browse the repository at this point in the history
Merge remote-tracking branch 'TriAnMan/bugfix-9859-v2' into bug-9859

* TriAnMan/bugfix-9859-v2:
  [modxcms#9859] Fix a near infinite recursion loop on TV ouptut filtering
  • Loading branch information
opengeek committed Jun 3, 2013
2 parents 23443e3 + fd8e7ce commit 058f716
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions core/docs/changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
This file shows the changes in recent releases of MODX. The most current release is usually the
development release, and is only shown to give an idea of what's currently in the pipeline.

- [#9859] Prevent conditional output filter recursion
- [#6138] Handle offline errors in RSS feeds
- Refresh file tree after removing file
- [#9946] Do not cache modResource::$_isForward
Expand Down
4 changes: 3 additions & 1 deletion core/model/modx/filters/modoutputfilter.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ function __construct(modX &$modx) {
/**
* Filters the output
*
* @param mixed $element The element to filter
* @param modElement $element The element to filter
*/
public function filter(&$element) {
$usemb = function_exists('mb_strlen') && (boolean)$this->modx->getOption('use_multibyte',null,false);
Expand Down Expand Up @@ -633,6 +633,8 @@ public function filter(&$element) {
$this->modx->log(modX::LOG_LEVEL_ERROR,$e->getMessage());
}
}
// convert $output to string if there were any processing
$output = (string)$output;
}
}

Expand Down

0 comments on commit 058f716

Please sign in to comment.