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:
-rwxr-xr-xChangeLog4
-rw-r--r--read_dump.php17
2 files changed, 9 insertions, 12 deletions
diff --git a/ChangeLog b/ChangeLog
index 50dca3fb49..60cc2f98ce 100755
--- a/ChangeLog
+++ b/ChangeLog
@@ -5,6 +5,10 @@ phpMyAdmin - Changelog
$Id$
$Source$
+2003-11-20 Michal Cihar <nijel@users.sourceforge.net>
+ * read_dump.php: Show message about failing upload in all cases, removed
+ some PHP compatibility code.
+
2003-11-20 Garvin Hicking <me@supergarv.de>
* libraries/auth/*, libraries/dbg/*, libraries/export/*
(work in progress)
diff --git a/read_dump.php b/read_dump.php
index cd20a51b6e..bb12b9fdb9 100644
--- a/read_dump.php
+++ b/read_dump.php
@@ -82,13 +82,7 @@ if ($sql_file != 'none') {
// || file_exists($cfg['UploadDir'] . $sql_localfile)) {
if (file_exists($sql_file)
&& ((isset($sql_localfile) && $sql_file == $cfg['UploadDir'] . $sql_localfile) || is_uploaded_file($sql_file))) {
- $open_basedir = '';
- if (PMA_PHP_INT_VERSION >= 40000) {
- $open_basedir = @ini_get('open_basedir');
- }
- if (empty($open_basedir)) {
- $open_basedir = @get_cfg_var('open_basedir');
- }
+ $open_basedir = @ini_get('open_basedir');
if (!isset($sql_file_compression)) $sql_file_compression = '';
@@ -109,12 +103,11 @@ if ($sql_file != 'none') {
}
else {
$sql_file_new = $tmp_subdir . basename($sql_file);
- if (PMA_PHP_INT_VERSION < 40003) {
- copy($sql_file, $sql_file_new);
- } else {
- move_uploaded_file($sql_file, $sql_file_new);
- }
+ move_uploaded_file($sql_file, $sql_file_new);
$sql_query = PMA_readFile($sql_file_new, $sql_file_compression);
+ if ($sql_query == FALSE) {
+ $message = $strFileCouldNotBeRead;
+ }
unlink($sql_file_new);
}
}