[wp-trac] [WordPress Trac] #8407: Endless loop of upgrade

WordPress Trac wp-trac at lists.automattic.com
Fri Nov 28 01:25:12 GMT 2008


#8407: Endless loop of upgrade
---------------------+------------------------------------------------------
 Reporter:  Malaiac  |       Owner:     
     Type:  defect   |      Status:  new
 Priority:  normal   |   Milestone:  2.7
Component:  Upgrade  |     Version:  2.7
 Severity:  normal   |    Keywords:     
---------------------+------------------------------------------------------
 An endless loop of upgrade can happen.
 It seems the cause is the test in wp_upgrade()

 {{{
         if ( $wp_db_version == $wp_current_db_version )
                 return;
 }}}

 While the test in admin.php is :
 {{{
 if ( get_option('db_version') != $wp_db_version ) {
         wp_redirect(admin_url('upgrade.php?_wp_http_referer=' .
 urlencode(stripslashes($_SERVER['REQUEST_URI']))));
         exit;
 }
 }}}

 I just got a WP2.7 install with
 {{{
 // in upgrade.php
 echo "<br />$wp_db_version == $wp_current_db_version";
 // > 9872 == 9872
 }}}
 so the upgrade process never take place
 but
 {{{
 // in admin.php
 echo get_option('db_version') .' != '.$wp_db_version;
 // > 9771 != 9872
 }}}
 always redirect

-- 
Ticket URL: <http://trac.wordpress.org/ticket/8407>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list