[wp-trac] [WordPress Trac] #18598: When "sidebars_widgets" option is malformed, an infinite loop occurs
WordPress Trac
wp-trac at lists.automattic.com
Mon Sep 5 23:42:15 UTC 2011
#18598: When "sidebars_widgets" option is malformed, an infinite loop occurs
--------------------------+-----------------------------
Reporter: Viper007Bond | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Widgets | Version: 3.3
Severity: normal | Keywords: needs-patch
--------------------------+-----------------------------
My `sidebars_widgets` option is set to this:
{{{
a:1:{s:9:"sidebar-1";a:3:{i:0;s:7:"links-2";i:1;s:12:"categories-2";i:2;s:10:"archives-2";}}
}}}
This results in an infinite loop between `retrieve_widgets()` and
`wp_get_sidebars_widgets()`.
{{{
( ! ) Fatal error: Maximum function nesting level of '100' reached,
aborting! in D:\Webserver\htdocs\wordpress-dev\wp-includes\cache.php on
line 415
Call Stack
# Time Memory Function Location
1 0.0010 180696 {main}( ) ..\themes.php:0
2 0.0017 279048 require_once( 'D:\Webserver\htdocs\wordpress-dev
\wp-admin\admin.php' ) ..\themes.php:10
3 0.0019 303424 require_once( 'D:\Webserver\htdocs\wordpress-dev
\wp-load.php' ) ..\admin.php:30
4 0.0022 318672 require_once( 'D:\Webserver\htdocs\wordpress-dev
\wp-config.php' ) ..\wp-load.php:29
5 0.0028 418968 require_once( 'D:\Webserver\htdocs\wordpress-dev
\wp-settings.php' ) ..\wp-config.php:85
6 0.1728 19104776 do_action( ) ..\wp-settings.php:303
7 0.1805 19115840 call_user_func_array ( )
..\plugin.php:405
8 0.1805 19115968 wp_widgets_init( ) ..\plugin.php:0
9 0.1811 19131040 register_widget( ) ..\default-
widgets.php:1147
10 0.1811 19131280 WP_Widget_Factory->register( )
..\widgets.php:431
11 0.1811 19132032 WP_Widget_Recent_Comments->__construct( )
..\widgets.php:324
12 0.1812 19133736 is_active_widget( ) ..\default-
widgets.php:603
13 0.1812 19134792 wp_get_sidebars_widgets( )
..\widgets.php:926
14 0.1817 19138232 retrieve_widgets( )
..\widgets.php:1059
15 0.1829 19126896 wp_get_sidebars_widgets( )
..\widgets.php:1222
16 0.1835 19130216 retrieve_widgets( )
..\widgets.php:1059
}}}
The consensus in #wordpress-dev is that a break is missing before `case 2
:` in `wp_get_sidebars_widgets()`. I'm not sure I agree, but either way
it's a bug.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/18598>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list