Make WordPress Core

Ticket #3354: shutdown.diff

File shutdown.diff, 996 bytes (added by ryan, 18 years ago)
  • wp-includes/default-filters.php

     
    173173add_action('admin_print_scripts', 'wp_print_scripts', 20);
    174174add_action('mce_options', '_mce_set_direction');
    175175add_action('init', 'smilies_init', 5);
    176 
    177176add_action( 'plugins_loaded', 'wp_maybe_load_widgets', 0 );
     177add_action( 'shutdown', 'wp_ob_end_flush_all', 1);
    178178
    179179?>
     180 No newline at end of file
  • wp-includes/functions.php

     
    15251525        ksort($submenu['themes.php'], SORT_NUMERIC);
    15261526}
    15271527
     1528// For PHP 5.2, make sure all output buffers are flushed
     1529// before our singletons our destroyed.
     1530function wp_ob_end_flush_all()
     1531{
     1532        while ( @ob_end_flush() );
     1533}
     1534
    15281535?>
     1536 No newline at end of file