[wp-trac] [WordPress Trac] #17817: do_action/apply_filters/etc. recursion on same filter kills underlying call
WordPress Trac
noreply at wordpress.org
Sun Oct 4 13:26:28 UTC 2015
#17817: do_action/apply_filters/etc. recursion on same filter kills underlying call
-------------------------------------------------+-------------------------
Reporter: kernfel | Owner: nacin
Type: defect (bug) | Status: reviewing
Priority: normal | Milestone: 4.4
Component: Plugins | Version: 2.2
Severity: normal | Resolution:
Keywords: has-unit-tests has-patch needs- | Focuses:
testing |
-------------------------------------------------+-------------------------
Changes (by ocean90):
* keywords: has-unit-tests has-patch commit => has-unit-tests has-patch
needs-testing
Comment:
I have applied [attachment:17817.7.diff] on my dotorg sandbox and it broke
our forums which are running bbPress trunk.
I can reproduce the same with the current stable version 2.5.8 of bbPress
on my local install. These are the warnings I get:
{{{
( ! ) Warning: ksort() expects parameter 1 to be array, object given in
/srv/www/wp-shared/develop-plugins/bbpress/includes/core/template-
functions.php on line 316
Call Stack
# Time Memory Function Location
1 0.0018 244024 {main}( ) .../index.php:0
2 0.0025 244472 require( '/srv/www/wp-develop/svn/src/wp-blog-
header.php' ) .../index.php:17
3 0.0028 245368 require_once( '/srv/www/wp-develop/svn/src/wp-
load.php' ) .../wp-blog-header.php:12
4 0.0038 246400 require_once( '/srv/www/wp-develop/svn/wp-
config.php' ) .../wp-load.php:42
5 0.0041 249208 require_once( '/srv/www/wp-develop/svn/src/wp-
settings.php' ) .../wp-config.php:102
6 0.1794 4354752 do_action( string(17), ??? ) .../wp-
settings.php:336
7 0.1794 4355424 WP_Hook->do_action( array(1) ) .../plugin.php:454
8 0.1794 4356320 call_user_func_array:{/srv/www/wp-develop/svn/src
/wp-includes/class-wp-hook.php:282} ( string(21), array(1) ) .../class-
wp-hook.php:282
9 0.1795 4356688 bbp_after_setup_theme( string(0) ) .../class-
wp-hook.php:282
10 0.1795 4356736 do_action( string(21), ??? ) .../sub-
actions.php:345
11 0.1795 4357408 WP_Hook->do_action( array(1) ) .../plugin.php:454
12 0.1796 4358560 call_user_func_array:{/srv/www/wp-develop/svn/src
/wp-includes/class-wp-hook.php:282} ( string(24), array(1) ) .../class-
wp-hook.php:282
13 0.1796 4358936 bbp_load_theme_functions( string(0) ) .../class-
wp-hook.php:282
14 0.1796 4359104 bbp_locate_template( string(21), bool, ??? )
.../template-loader.php:162
15 0.1796 4359304 bbp_get_template_stack( ) .../template-
functions.php:65
16 0.1796 4359760 ksort ( object(WP_Hook)[750] ) .../template-
functions.php:316
// Nine occurrences of this one:
( ! ) Notice: Undefined index: function in /srv/www/wp-shared/develop-
plugins/bbpress/includes/core/template-functions.php on line 326
Call Stack
# Time Memory Function Location
1 0.0018 244024 {main}( ) .../index.php:0
2 0.0025 244472 require( '/srv/www/wp-develop/svn/src/wp-blog-
header.php' ) .../index.php:17
3 0.0028 245368 require_once( '/srv/www/wp-develop/svn/src/wp-
load.php' ) .../wp-blog-header.php:12
4 0.0038 246400 require_once( '/srv/www/wp-develop/svn/wp-
config.php' ) .../wp-load.php:42
5 0.0041 249208 require_once( '/srv/www/wp-develop/svn/src/wp-
settings.php' ) .../wp-config.php:102
6 0.1794 4354752 do_action( string(17), ??? ) .../wp-
settings.php:336
7 0.1794 4355424 WP_Hook->do_action( array(1) ) .../plugin.php:454
8 0.1794 4356320 call_user_func_array:{/srv/www/wp-develop/svn/src
/wp-includes/class-wp-hook.php:282} ( string(21), array(1) ) .../class-
wp-hook.php:282
9 0.1795 4356688 bbp_after_setup_theme( string(0) ) .../class-
wp-hook.php:282
10 0.1795 4356736 do_action( string(21), ??? ) .../sub-
actions.php:345
11 0.1795 4357408 WP_Hook->do_action( array(1) ) .../plugin.php:454
12 0.1796 4358560 call_user_func_array:{/srv/www/wp-develop/svn/src
/wp-includes/class-wp-hook.php:282} ( string(24), array(1) ) .../class-
wp-hook.php:282
13 0.1796 4358936 bbp_load_theme_functions( string(0) ) .../class-
wp-hook.php:282
14 0.1796 4359104 bbp_locate_template( string(21), bool, ??? )
.../template-loader.php:162
15 0.1796 4359304 bbp_get_template_stack( ) .../template-
functions.php:65
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/17817#comment:156>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list