Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc Delisle <marc@infomarc.info>2004-09-20 21:47:40 +0400
committerMarc Delisle <marc@infomarc.info>2004-09-20 21:47:40 +0400
commit8b4513e16a65f2d068fe7cd3b2a36e521ca37485 (patch)
treecbabe21f754937e2a8107ab42960d71111542d1f
parent0b851a1b30ce532a5fa28bea08d5198729f3648a (diff)
bug #1030644 importing when last table exported was empty
-rwxr-xr-xChangeLog6
-rw-r--r--libraries/read_dump.lib.php4
-rw-r--r--read_dump.php11
3 files changed, 15 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index f79e58567b..3f1c597703 100755
--- a/ChangeLog
+++ b/ChangeLog
@@ -5,8 +5,12 @@ phpMyAdmin - Changelog
$Id$
$Source$
+2004-09-20 Marc Delisle <lem9@users.sourceforge.net>
+ * read_dump.php, libraries/read_dump.lib.php: bug #1030644,
+ error importing when last table exported was empty
+
2004-09-20 Michal Čihař <michal@cihar.com>
- * Documentation.html: Add info about theme generations.
+ * Documentation.html: Add info about theme generations.
2004-09-19 Alexander M. Turek <me@derrabus.de>
* Documentation.html: Clarification.
diff --git a/libraries/read_dump.lib.php b/libraries/read_dump.lib.php
index f5a4255301..f8a97ea1f0 100644
--- a/libraries/read_dump.lib.php
+++ b/libraries/read_dump.lib.php
@@ -18,7 +18,9 @@
*/
function PMA_splitSqlFile(&$ret, $sql, $release)
{
- $sql = trim($sql);
+ // do not trim, see bug #1030644
+ //$sql = trim($sql);
+ $sql = rtrim($sql, "\n\r");
$sql_len = strlen($sql);
$char = '';
$string_start = '';
diff --git a/read_dump.php b/read_dump.php
index a1bd251f8b..5883bfa177 100644
--- a/read_dump.php
+++ b/read_dump.php
@@ -130,13 +130,16 @@ if ($sql_file != 'none') {
// Kanji convert SQL textfile 2002/1/4 by Y.Kawada
if (@function_exists('PMA_kanji_str_conv')) {
- $sql_tmp = trim($sql_query);
+ // do not trim here: see bug #1030644
+ //$sql_tmp = trim($sql_query);
+ $sql_tmp = $sql_query;
PMA_change_enc_order();
$sql_query = PMA_kanji_str_conv($sql_tmp, $knjenc, isset($xkana) ? $xkana : '');
PMA_change_enc_order();
-} else {
- $sql_query = trim($sql_query);
-}
+} //else {
+ // do not trim here: see bug #1030644
+ //$sql_query = trim($sql_query);
+//}
// $sql_query come from the query textarea, if it's a reposted query gets its
// 'true' value