From f3d41b7b38e53b8d6e491dc191b7f2b0b4fa56d6 Mon Sep 17 00:00:00 2001 From: Michael Adams Date: Wed, 6 May 2015 21:50:29 +0000 Subject: [PATCH] Upgrade: Ensure unintelligible DB schemas don't result in content loss. Merge of [32417] to the 4.2 branch. See #32165. Props ocean90. Built from https://develop.svn.wordpress.org/branches/4.2@32418 git-svn-id: http://core.svn.wordpress.org/branches/4.2@32388 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/upgrade.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-admin/includes/upgrade.php b/wp-admin/includes/upgrade.php index e43706acf2..34148f3eee 100644 --- a/wp-admin/includes/upgrade.php +++ b/wp-admin/includes/upgrade.php @@ -1469,7 +1469,7 @@ function upgrade_422() { ); } - if ( 'byte' !== $content_length['type'] ) { + if ( 'byte' !== $content_length['type'] || 0 === $content_length['length'] ) { // Sites with malformed DB schemas are on their own. return; }