Permalink
Browse files

Should fix encoding issue with PowerFS

  • Loading branch information...
1 parent 8e42238 commit aaf0ec895ab486b0afdd900007903ca596303aa7 @cdujeu cdujeu committed Sep 26, 2016
Showing with 3 additions and 1 deletion.
  1. +3 −1 core/src/plugins/action.powerfs/PowerFSController.php
@@ -28,6 +28,7 @@
use Pydio\Core\Controller\Controller;
use Pydio\Core\Services\LocaleService;
use Pydio\Core\Services\ApplicationState;
+use Pydio\Core\Utils\TextEncoder;
use Pydio\Core\Utils\Vars\InputFilter;
use Pydio\Core\PluginFramework\Plugin;
use Pydio\Core\PluginFramework\PluginsService;
@@ -83,7 +84,8 @@ public function switchAction(ServerRequestInterface &$request, ResponseInterface
case "postcompress_download":
$archive = ApplicationState::getAjxpTmpDir() . DIRECTORY_SEPARATOR . $httpVars["ope_id"] . "_" . InputFilter::decodeSecureMagic($httpVars["archive_name"], InputFilter::SANITIZE_FILENAME);
-
+ // This is a real filename on a local FS => toStorageEncoding
+ $archive = TextEncoder::toStorageEncoding($archive);
$archiveName = $httpVars["archive_name"];
if (is_file($archive)) {
$fileReader = new \Pydio\Core\Http\Response\FileReaderResponse($archive);

0 comments on commit aaf0ec8

Please sign in to comment.