From 66b4be9b746da0c00d73959be8f892a2a5edbeee Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Tue, 30 Jun 2015 17:12:23 -0400 Subject: [PATCH] bug #4972 Incorrect length computed for binary data Signed-off-by: Marc Delisle --- ChangeLog | 1 + libraries/DisplayResults.class.php | 2 +- tbl_get_field.php | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 0b8d7b1b5f..d5fa7f742e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,7 @@ phpMyAdmin - ChangeLog 4.4.11.0 (not yet released) - bug Missing selected/entered values when editing active options in visual query builder - bug #4969 Autoload from prefs_storage not behaving properly +- bug #4972 Incorrect length computed for binary data 4.4.10.0 (2015-06-17) - bug #4950 Issues in database selection for replication diff --git a/libraries/DisplayResults.class.php b/libraries/DisplayResults.class.php index 909e133343..ca0b6f1497 100644 --- a/libraries/DisplayResults.class.php +++ b/libraries/DisplayResults.class.php @@ -5126,7 +5126,7 @@ class PMA_DisplayResults if (isset($content)) { - $size = /*overload*/mb_strlen($content); + $size = /*overload*/mb_strlen($content, '8bit'); $display_size = PMA_Util::formatByteDown($size, 3, 1); $result .= ' - ' . $display_size[0] . ' ' . $display_size[1]; diff --git a/tbl_get_field.php b/tbl_get_field.php index 1ec3c5a8f9..f4570ebac1 100644 --- a/tbl_get_field.php +++ b/tbl_get_field.php @@ -49,7 +49,7 @@ if ($result === false) { PMA_downloadHeader( $table . '-' . $_GET['transform_key'] . '.bin', PMA_detectMIME($result), - /*overload*/mb_strlen($result) + /*overload*/mb_strlen($result, '8bit') ); echo $result; ?>