Check whether UploadDir is defined before using it.
This commit is contained in:
@@ -466,6 +466,8 @@ class PMA_File
|
|||||||
*/
|
*/
|
||||||
function setLocalSelectedFile($name)
|
function setLocalSelectedFile($name)
|
||||||
{
|
{
|
||||||
|
if (empty($GLOBALS['cfg']['UploadDir'])) return false;
|
||||||
|
|
||||||
$this->setName(PMA_userDir($GLOBALS['cfg']['UploadDir']) . PMA_securePath($name));
|
$this->setName(PMA_userDir($GLOBALS['cfg']['UploadDir']) . PMA_securePath($name));
|
||||||
if (! $this->isReadable()) {
|
if (! $this->isReadable()) {
|
||||||
$this->_error_message = $GLOBALS['strFileCouldNotBeRead'];
|
$this->_error_message = $GLOBALS['strFileCouldNotBeRead'];
|
||||||
@@ -875,4 +877,4 @@ class PMA_File
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
Reference in New Issue
Block a user