mirror of
https://github.com/misterunknown/ifm.git
synced 2025-08-11 02:24:00 +02:00
Fix zipnload temporary file
Signed-off-by: Marco Dickert <marco@misterunknown.de>
This commit is contained in:
@@ -812,7 +812,11 @@ IFM_ASSETS
|
|||||||
$this->jsonResponse( array( "status" => "ERROR", "message" => $this->l['invalid_filename'] ) );
|
$this->jsonResponse( array( "status" => "ERROR", "message" => $this->l['invalid_filename'] ) );
|
||||||
else {
|
else {
|
||||||
unset( $zip );
|
unset( $zip );
|
||||||
$dfile = $this->pathCombine( __DIR__, $this->config['tmp_dir'], uniqid( "ifm-tmp-" ) . ".zip" ); // temporary filename
|
if ($this->isAbsolutePath($this->config['tmp_dir']))
|
||||||
|
$dfile = $this->pathCombine( $this->config['tmp_dir'], uniqid( "ifm-tmp-" ) . ".zip" ); // temporary filename
|
||||||
|
else
|
||||||
|
$dfile = $this->pathCombine( __DIR__, $this->config['tmp_dir'], uniqid( "ifm-tmp-" ) . ".zip" ); // temporary filename
|
||||||
|
|
||||||
try {
|
try {
|
||||||
IFMArchive::createZip(realpath($d['filename']), $dfile, array($this, 'isFilenameValid'));
|
IFMArchive::createZip(realpath($d['filename']), $dfile, array($this, 'isFilenameValid'));
|
||||||
if( $d['filename'] == "." ) {
|
if( $d['filename'] == "." ) {
|
||||||
|
Reference in New Issue
Block a user